📂File uploads

Overview

Our API offers robust support for file uploads, allowing you to easily attach files or upload large amounts of data to R0. Whether it's an attachment for a contact or a bulk upload of contacts for an organization, we've made the process seamless.

Supported Endpoints for File Uploads

  1. Contact Attachment Upload: Attach files to a specific contact within an organization. More details available on its specific documentation page.

    Endpoint: /api/v1/orgs/{org_id}/contacts/{contact_id}/attachments

  2. Bulk Contacts Upload: Upload multiple contacts to a specified organization in a bulk manner. Check its dedicated documentation page for further specifics.

    Endpoint: /api/v1/orgs/{org_id}/bulk-upload

Generic Upload Instructions

  • Headers:

    • Authorization: Authenticate your request using a bearer token. Example: Bearer MRyvlph_GRghpQhJo71iRnCjvxm3Dnej_X3dZBDLrwY=

  • Parameters:

    • upload: The file you're uploading. In cURL commands, prefix with @ to indicate it's a file.

  • cURL Example:

curl -X POST \
     -H "Authorization: Bearer YOUR_TOKEN_HERE" \
     -F "upload=@YOUR_FILE_NAME.extension" \
     "https://web.r0app.com/api/v1/orgs/:org_id/contacts/:contact_id/attachments"

Accepted file types

  • CSV imports:

    • .csv

  • Contact attachments / file attachments:

    • PDF, and images (JPG, JPEG, PNG)

Response & Status Codes

Upon successful upload, you'll receive details of the uploaded file, like its storage location, filename, and size. Error responses will detail the issue.

Common status codes

  • 200 OK: Successful upload.

  • 400 Bad Request: Invalid request or missing parameters.

  • 401 Unauthorized: Invalid or expired token.

  • 500 Internal Server Error: Server error. Reach out to support.

Last updated