Skip to main content

Ingest Legacy

POST /ingest is a compatibility endpoint for direct post_video queue-item ingestion.
POST /ingest
New integrations should generally use the process-first public API. Use this endpoint only when you specifically need queue-item posting semantics keyed by account_id + content_id.

Request Example

curl -X POST "$PHONEFARM_BASE_URL/ingest" \
  -H "Authorization: Bearer $PHONEFARM_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "content_id": "content-2026-03-22-001",
    "account_id": "account_user095916355",
    "video_path": "https://assets.example.com/videos/content-2026-03-22-001.mp4",
    "caption": "Check out this recipe",
    "hashtags": ["cooking", "mealprep"],
    "sound_id": null,
    "cover_image_path": "https://assets.example.com/covers/content-2026-03-22-001.jpg",
    "callback_url": "https://ugc-tracker.example.com/phonefarm/post-result",
    "scheduling_hint": "2026-03-22T16:00:00-07:00",
    "metadata": {
      "source": "ugc-tracker"
    }
  }'

Accepted Response

{
  "status": "accepted",
  "queue_item_id": "7c1a07f6-1d55-4f79-a403-8a8420f1b62b",
  "content_id": "content-2026-03-22-001",
  "account_id": "account_user095916355",
  "queue_status": "QUEUED"
}

Duplicate Response

{
  "status": "duplicate",
  "queue_item_id": "7c1a07f6-1d55-4f79-a403-8a8420f1b62b",
  "content_id": "content-2026-03-22-001",
  "account_id": "account_user095916355",
  "queue_status": "SCHEDULED"
}

Request Fields

FieldTypeRequiredNotes
content_idstringyesCaller content identifier.
account_idstringyesActive target account id.
video_pathstringyesMust be a valid http(s) asset URL.
captionstringyesMax length 4000.
hashtagsstring[]noOptional hashtags list.
sound_idstring or nullnoOptional sound id.
cover_image_pathstring or nullnoMust be a valid http(s) asset URL when provided.
callback_urlstring or nullnoOptional per-item callback URL.
scheduling_hintstring or nullnoMust parse as ISO-8601 when provided.
metadataobjectnoFree-form metadata. Defaults to {}.

Validation Rules

  • video_path must be valid http(s).
  • cover_image_path must be valid http(s) when present.
  • assets are HEAD-checked before enqueue
  • caption must be non-empty and at most 4000 characters
  • account_id must resolve to an active account

Idempotency

Idempotency key:
(account_id, content_id)

Failure Modes

Status codeMeaning
401Missing or invalid bearer token.
404Account not found or inactive.
422Invalid payload, invalid URL, missing asset, or invalid timestamp.
500Unexpected enqueue failure.