{"openapi":"3.1.0","info":{"title":"DocuBorder API","version":"1.0.0","summary":"Pay-per-document API for US⇄Mexico family travel and permission documents (English/Spanish).","description":"Flow: GET /document-types → POST /quotes → POST /validate → POST /orders (returns checkout_url to pay and an access_token) → GET /orders/{id} with the bearer token until fulfilled, then download_url (single document) or downloads (one link per document, for a bundle such as mexico-family-trip-pack). Errors are RFC 9457 problem+json with a stable `code`. The same flow is available over MCP at /mcp. Not legal advice: we are not a law firm."},"servers":[{"url":"https://www.docuborder.com/api/v1"}],"paths":{"/document-types":{"get":{"operationId":"listDocumentTypes","summary":"List document types","responses":{"200":{"description":"The catalog","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/document-types/{id}":{"get":{"operationId":"getDocumentType","summary":"One document type with its input JSON Schema","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","enum":["child-travel-consent-one-parent","child-travel-consent-no-parents","minor-medical-authorization-travel","vehicle-owner-permission-mexico","child-travel-consent-generic","minor-travel-contact-sheet","mexico-family-trip-pack"]}}],"responses":{"200":{"description":"The document type","content":{"application/json":{"schema":{"type":"object"}}}},"404":{"description":"Error (404); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/quotes":{"post":{"operationId":"createQuote","summary":"Price quote","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Offering"}}}},"responses":{"200":{"description":"Quote","content":{"application/json":{"schema":{"type":"object"}}}},"404":{"description":"Error (404); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Error (422); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/validate":{"post":{"operationId":"validateInputs","summary":"Validate inputs for free","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OfferingWithInputs"}}}},"responses":{"200":{"description":"valid: true or field errors","content":{"application/json":{"schema":{"type":"object"}}}},"404":{"description":"Error (404); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Error (422); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Error (429); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/previews":{"post":{"operationId":"createPreview","summary":"Watermarked preview","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OfferingWithInputs"}}}},"responses":{"201":{"description":"Preview","content":{"application/json":{"schema":{"type":"object"}}}},"404":{"description":"Error (404); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Error (422); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Error (429); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/previews/{token}":{"get":{"operationId":"getPreview","summary":"Preview metadata","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Preview","content":{"application/json":{"schema":{"type":"object"}}}},"404":{"description":"Error (404); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Error (429); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/previews/{token}/pages/{n}":{"get":{"operationId":"getPreviewPage","summary":"Preview page image","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string"}},{"name":"n","in":"path","required":true,"schema":{"type":"integer","minimum":1}}],"responses":{"200":{"description":"PNG","content":{"image/png":{"schema":{"type":"string","format":"binary"}}}},"404":{"description":"Error (404); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Error (429); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/orders":{"post":{"operationId":"createOrder","summary":"Create an order","description":"Returns checkout_url (pay there) and a one-time access_token. Providers that use HTTP 402 answer 402 with a challenge instead.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OfferingWithInputs"}}}},"responses":{"201":{"description":"Order created; payment required","content":{"application/json":{"schema":{"type":"object"}}}},"402":{"description":"Payment challenge","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (404); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"description":"Error (422); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Error (429); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"502":{"description":"Error (502); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}},"/orders/{id}":{"get":{"operationId":"getOrder","summary":"Order status; download_url (single document) or downloads (bundle) when fulfilled","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"security":[{"orderToken":[]}],"responses":{"200":{"description":"Order","content":{"application/json":{"schema":{"type":"object"}}}},"401":{"description":"Error (401); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"404":{"description":"Error (404); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"429":{"description":"Error (429); see code.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}}},"components":{"securitySchemes":{"orderToken":{"type":"http","scheme":"bearer","description":"access_token returned by POST /orders."}},"schemas":{"Offering":{"type":"object","required":["document_type_id","jurisdiction","language"],"additionalProperties":false,"properties":{"document_type_id":{"type":"string","enum":["child-travel-consent-one-parent","child-travel-consent-no-parents","minor-medical-authorization-travel","vehicle-owner-permission-mexico","child-travel-consent-generic","minor-travel-contact-sheet","mexico-family-trip-pack"]},"jurisdiction":{"type":"string","enum":["us-to-mx","mx-departure","us-intl"],"description":"us-to-mx: Travel from the U.S. to Mexico; mx-departure: Leaving Mexico; us-intl: International travel from the U.S."},"language":{"type":"string","enum":["en","es"]}}},"OfferingWithInputs":{"allOf":[{"$ref":"#/components/schemas/Offering"}],"type":"object","required":["inputs"],"properties":{"inputs":{"type":"object","description":"Matches input_schema from GET /document-types."}}},"Problem":{"type":"object","required":["type","title","status","code","detail"],"properties":{"type":{"type":"string","format":"uri"},"title":{"type":"string"},"status":{"type":"integer"},"code":{"type":"string","enum":["VALIDATION_FAILED","INVALID_JSON","PAYLOAD_TOO_LARGE","UNSUPPORTED_MEDIA_TYPE","METHOD_NOT_ALLOWED","NOT_FOUND","DOCUMENT_TYPE_NOT_FOUND","JURISDICTION_NOT_SUPPORTED","LANGUAGE_NOT_SUPPORTED","PREVIEW_NOT_FOUND","ORDER_NOT_FOUND","UNAUTHORIZED","RATE_LIMITED","PAYMENT_REQUIRED","PAYMENT_PROVIDER_ERROR","ORDER_NOT_PAYABLE","SERVICE_UNAVAILABLE","INTERNAL_ERROR"]},"detail":{"type":"string"},"detail_en":{"type":"string"},"detail_es":{"type":"string"},"request_id":{"type":"string"},"errors":{"type":"array","items":{"type":"object","properties":{"path":{"type":"string"},"code":{"type":"string","enum":["REQUIRED","INVALID_TYPE","TOO_SHORT","TOO_LONG","INVALID_FORMAT","UNSUPPORTED_CHARACTERS","INVALID_EMAIL","INVALID_PHONE","INVALID_DATE","INVALID_OPTION","TOO_FEW_ITEMS","TOO_MANY_ITEMS","UNKNOWN_FIELD","DATE_ORDER","DATE_AFTER_TRIP","CHILD_NOT_MINOR","SAME_PERSON","UNDER_AGE"]},"message_en":{"type":"string"},"message_es":{"type":"string"}}}}}}}}}