Skip to content

POST /backtraces

Description

Create a new backtrace.

Authentication

  • Required: Yes
  • Method: Bearer token

Headers

  • Authorization: Bearer [AUTH_TOKEN]
  • Content-Type: application/json

Parameters

Query Parameters

  • format: string (Optional)
    Values: json, xml
    Overrides the Request Accept header.
  • human: boolean (Optional)
    Values: true, false
    If set to 'true', the response will be in a structured, more human-readable form.
  • job_id: string (Required)
    The job id of the original video the copy to trace belongs to.

Request Body

  • backtrace: object (Required)
    • pipeline: object (Required)
      • id: string (Required)
        References the pipeline on which to perform the Backtrace. This specifies the input locations for the Backtrace's input (input_name will be relative to the input directive configured in the respective pipeline).
    • input: object (Required)
      • input_name: string (Required)
        The URI/Filename of the input video file to backtrace. If given as a relative path, it is treated relative to the base input uri set in the referenced Pipeline.

Example Request

bash
curl -X POST "https://api.xvid.com/v1/titles/backtraces/?job_id=56f023dee4b00c798948107a&human=true&show_null=true" \
  -H "Authorization: Bearer AUTH_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "backtrace": {
      "pipeline": {
        "id": "552b87a814eab3a29d1b3d90"
      },
      "input": {
        "input_name": "uploads/QOSifPpTys1wcnEli3aXo50nyj2JROdO/movie.mp4"
      }
    }
  }'

Response

Success (201 Created)

json
{
  "backtrace": {
    "id": "559b65d814eabe5486ff6ed5",
    "pipeline": {
      "id": "552b87a814eab3a29d1b3d90",
      "href": "https://api.xvid.com/v1/pipelines/552b87a814eab3a29d1b3d90"
    },
    "input": {
      "input_name": "uploads/QOSifPpTys1wcnEli3aXo50nyj2JROdO/movie.mp4"
    },
    "status": "SUCCESS",
    "percentage_completed": 100,
    "error_msg": null,
    "error_code": null,
    "finished_at": 1436247563709,
    "version": 1,
    "user": {
      "id": "552b874d14eab3a29d1b3d8d",
      "href": "https://api.xvid.com/v1/users/552b874d14eab3a29d1b3d8d"
    },
    "created_at": 1436247512758,
    "updated_at": 1436247512758,
    "href": "https://api.xvid.com/v1/titles/backtraces/559b65d814eabe5486ff6ed5"
  }
}

Error Responses

400 Bad Request

json
{
  "error": "Invalid request parameters"
}

401 Unauthorized

json
{
  "error": "Authentication required"
}

500 Internal Server Error

json
{
  "error": "Internal server error"
}

Notes

  • Ensure all required fields are provided.
  • Additional validation rules and potential error messages need to be documented.