EndpointsCreate source

Create source

curl -X POST "//v1/spaces/example_string/sources" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_TOKEN (API Key)" \
  -d '{
  "type": "URI",
  "name": "John Doe",
  "initial_data": {
    "url": "example_string",
    "uri": "example_string",
    "source_ids": [
      "example_string"
    ],
    "data": "example_string"
  },
  "collectionId": "example_string",
  "instructions": {},
  "description": "example_string"
}'
{}
POST
/v1/spaces/{spaceId}/sources
POST
Bearer Token (API Key)
Bearer Tokenstring
Required

User API Key. Create in the Ctxfy dashboard or via POST /v1/api-keys. Use Bearer <api_key> in Authorization header.

User API Key. Create in the Ctxfy dashboard or via POST /v1/api-keys. Use Bearer <api_key> in Authorization header.
Content-Typestring
Required

The media type of the request body

Options: application/json
typestring
Required
Options: URI, FILE, CONTENT, COMPOSITION
initial_dataobject
Required

URI: url or uri required. COMPOSITION: source_ids required. FILE: data with fileKey from S3 presign response. CONTENT: data with inline content.

instructionsobject
Required

Processing options. Optional postback_url (HTTPS) — Ctxfy sends an HTTP POST when the source reaches COMPLETED, FAILED, or CANCELED.

Request Preview
Response

Response will appear here after sending the request

Authentication

header
Authorizationstring
Required

Bearer token (API Key). User API Key. Create in the Ctxfy dashboard or via POST /v1/api-keys. Use Bearer <api_key> in Authorization header.

Path Parameters

Body

application/json
typestring
Required
Allowed values:URIFILECONTENTCOMPOSITION
initial_dataobject
Required

URI: url or uri required. COMPOSITION: source_ids required. FILE: data with fileKey from S3 presign response. CONTENT: data with inline content.

instructionsobject
Required

Processing options. Optional postback_url (HTTPS) — Ctxfy sends an HTTP POST when the source reaches COMPLETED, FAILED, or CANCELED.

Responses