dockStatusId. Use this ID to call the Get Dock Status API and verify the successful import of the tool.
To import a tool, follow the steps below:
- Upload Files: Use the File Upload API to upload the files for the flow definition, app definition, and environment variables. Learn more. This API returns unique file IDs for each file.
- Import the Tool: Call the Import Tools API using the retrieved file IDs along with the tool name.
- Track import Status: The API response returns a
dockStatusIdthat helps monitor the import progress using the Get Dock Status API.
| Method | POST |
|---|---|
| Endpoint | https://{host}/api/public/tools/import |
| Content Type | application/json |
| Authorization | X-api-key - The API key used for authentication. |
Query Parameters
| PARAMETER | DESCRIPTION | TYPE | REQUIRED/OPTIONAL |
|---|---|---|---|
| host | The environment URL. For example, https://agent-platform.domain.ai/ | String | Required |
Sample Request
Body Parameters
| PARAMETER | DESCRIPTION | TYPE | REQUIRED/OPTIONAL |
|---|---|---|---|
| toolDataFileId | The file ID for the tool data file. | String | Required |
| flowDataFileId | The file ID for the flow data file. | String | Required |
| envVariablesFileId | Thefile IDfor the environment variables | String | Optional |
| toolName | The name of the tool. | String | Required |
Sample Response
Response Parameters
| PARAMETER | DESCRIPTION | TYPE | SAMPLE VALUE |
|---|---|---|---|
| dockStatusId | The unique identifier to track the status of the import action. | String | Example: ds-cxxxxxx5-dxxd-5xxf-9xxd-0xxxxx6c5xx8 |
| toolId | The unique identifier for the tool. | String | Example: a-8xxxxxxe-6xxe-5xx1-8xxc-b3xxxxx80xx6 |
| jobType | The type of job being performed. | String | TOOLS |
| action | The action that’s performed on the tool/model. | String | IMPORT |
| status | The current status of the job. | String | IN_PROGRESS, SUCCESS, or FAILED |