Importing Data via REST API
Upload a CSV to Agentnoon's REST API using an API KEY. Ensure data matches the schema with your account manager. Customize the upload frequency as needed.
Prerequisites
Agentnoon account
Valid API key for authentication. This can be requested from [email protected]
CSV file to be uploaded.
API endpoint URL for file upload.
Whitelisted IP Address - Contact [email protected] to whitelist the IP address from which you will be uploading data.
Schema Configuration - Work with your account manager to configure Agentnoon to align with the schema of the data being uploaded.
Upload Cadence - Determine the appropriate upload frequency based on your business needs.
Steps
Prepare the CSV File
Ensure the CSV file is properly formatted.
Verify that the data within the CSV file is accurate and complete.
Configure Agentnoon
Collaborate with your account manager to configure Agentnoon's schema to match the structure of the data within your CSV file.
Construct the API Request
Use an HTTP client or programming language capable of making POST requests.
Set the API endpoint URL as the destination for the request.
Include the CSV file in the request body.
Set the `Content-Type` header to `multipart/form-data`.
Include the bearer token in the `API-KEY` header as `<api-key>`.
Request the Board ID to Agentnoon’s account manager
Send the API Request
Execute the constructed API request.
Upload API URI: https://api.agentnoon.co/v1/import-mapping/<my_board_id>/import-csv-file
Handle the API Response
Check the HTTP status code of the response.
200 OK indicates a successful upload.
Other status codes indicate errors.
Parse the response body for any additional information or error messages.
Summary Checklist
Verify the API KEY
Prepare the CSV file.
Work with your account manager to configure the Agentnoon schema.
Contact [email protected] to whitelist your IP address.
Construct the API request.
Send the API request.
Handle the API response.
Example Request Headers
Header
Value
API-KEY
`an_U8RgYNME5Hc88Knb`
Content-Type
`multipart/form-data`
Example Request Body
The request body should be in `multipart/form-data` format, including the CSV file. The specific format will depend on the HTTP client or programming language used.
Error Handling
HTTP Status Code
Description
400
Bad Request - The request could not be understood or contained invalid data.
401
Unauthorized - Authentication failed due to an invalid or missing API Key.
403
Forbidden - The request was valid, but the server is refusing to respond to it. Contact [email protected] if you receive this error to ensure your IP has been whitelisted.
415
Unsupported Media Type - The server does not support the provided file type.
500
Internal Server Error - An unexpected error occurred on the server.
Last updated
Was this helpful?