> ## Documentation Index
> Fetch the complete documentation index at: https://docs.escrybe.com.br/llms.txt
> Use this file to discover all available pages before exploring further.

# Get an order



## OpenAPI

````yaml /openapi/escrybe.en.yaml get /api/v2/get/{securityToken}/{job_id}
openapi: 3.1.0
info:
  title: Escrybe API
  version: 1.0.0
  description: >
    REST API for the Escrybe platform — send physical letters, registered
    letters, telegrams and e-Carta through Brazilian Correios, dispatch legally
    registered e-mails, and send WhatsApp messages with certified timestamps.


    ## Authentication

    Every account has a personal **`securityToken`** (find it in the panel under
    *Account → API*). Three products use it differently:


    | Product | Scheme | How | |---------|--------|-----| | Letters / Telegram /
    e-Carta, Registered E-mail, Receipts | API token | Send `userSecurityToken`
    as a query/body parameter, or `securityToken` as a header | | WhatsApp |
    HTTP Basic | `Authorization: Basic base64(email:securityToken)` |


    > The letter and e-mail **read** routes (`get`, `balance`, `download`, >
    `delete`) take the token as the first URL **path** segment — e.g. >
    `/api/v2/get/{securityToken}/{job_id}`.


    ## Response envelopes

    Most endpoints reply with the standard envelope `{"status": <http code>,
    "status_message": "...", "data": ...}` — this covers Letters/Telegram,
    Registered E-mail, and the WhatsApp message and sender endpoints. The
    WhatsApp **template** endpoints (and template sync) use `{"code": <http
    code>, "status": "success|error", "message": "...", "data": ...,
    "request_id": "..."}`; the logo endpoint uses the same shape without
    `request_id`. See the schema of each endpoint.


    A request that is accepted returns an HTTP `200` with a success payload;
    validation problems return `400`, bad credentials `401`, and forbidden
    access `403`. Unsupported HTTP methods return `405`, repeated failed
    authentication attempts return `429`, and the letter and e-mail endpoints
    return `503` during maintenance windows.
  contact:
    name: Escrybe Support
    url: https://escrybe.com.br
servers:
  - url: https://app.escrybe.com.br
    description: Production
  - url: https://homolog.escrybe.com.br
    description: Staging
security:
  - securityTokenQuery: []
tags:
  - name: Letters & Telegram
    description: Create and manage letter, telegram and e-Carta orders (Correios).
  - name: Account & Favorites
    description: Account balance, saved contacts and sender logo.
  - name: Registered E-mail
    description: Send and track legally registered e-mails.
  - name: WhatsApp Messages
    description: Send WhatsApp messages and download certified-timestamp attestations.
  - name: WhatsApp Senders
    description: Manage WhatsApp Business numbers (senders).
  - name: WhatsApp Templates
    description: Create, sync and manage WhatsApp message templates.
  - name: Receipts
    description: Download legal receipts for any order.
paths:
  /api/v2/get/{securityToken}/{job_id}:
    get:
      tags:
        - Letters & Telegram
      summary: Get an order
      operationId: getOrder
      parameters:
        - $ref: '#/components/parameters/SecurityTokenPath'
        - $ref: '#/components/parameters/JobIdPath'
      responses:
        '200':
          description: Order found
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/V2Envelope'
                  - properties:
                      data:
                        $ref: '#/components/schemas/OrderDetail'
        '400':
          $ref: '#/components/responses/V2BadRequest'
        '401':
          $ref: '#/components/responses/V2Unauthorized'
      security: []
components:
  parameters:
    SecurityTokenPath:
      name: securityToken
      in: path
      required: true
      schema:
        type: string
      description: Your account security token (used as authentication).
    JobIdPath:
      name: job_id
      in: path
      required: true
      schema:
        type: string
      description: >-
        Order visual id — digits for letters/telegrams (e.g. 2607031);
        registered e-mail ids start with `E` (e.g. E2607031).
  schemas:
    V2Envelope:
      type: object
      properties:
        status:
          type: integer
          example: 200
        status_message:
          type: string
        data:
          oneOf:
            - type: object
            - type: string
            - type: 'null'
    OrderDetail:
      type: object
      properties:
        id:
          type: string
        numPages:
          type: integer
        name:
          type: string
        addr1:
          type: string
        street_number:
          type: string
        addr2:
          type: string
        zip:
          type: string
        city:
          type: string
        state:
          type: string
        country:
          type: string
        name_sender:
          type: string
        addr1_sender:
          type: string
        street_number_sender:
          type: string
        addr2_sender:
          type: string
        zip_sender:
          type: string
        city_sender:
          type: string
        state_sender:
          type: string
        country_sender:
          type: string
        shipType:
          type: integer
        tracking:
          type: string
          nullable: true
        status:
          type: integer
          description: >-
            0 Processing · 1 Production · 2 Insufficient credits · 3 Printed · 4
            Posted · 5 Cancelled · 6 Returned
        status_delivery:
          type: string
          nullable: true
        pdf_available:
          type: boolean
        rr_available:
          type: boolean
        rr_count:
          type: integer
        sender_copy_available:
          type: boolean
        telegram_copy_available:
          type: boolean
        files:
          type: array
          items:
            type: object
            properties:
              name:
                type: string
              type:
                type: string
              created_at:
                type: string
        dateSubmit:
          type: string
        dateLastChange:
          type: string
        value:
          type: number
          format: float
        tag:
          type: string
        tracking_records:
          type: object
          nullable: true
        tracking_records_last_update:
          type: string
          nullable: true
        telegram_info:
          type: object
          nullable: true
          description: Only present when shipType=4.
  responses:
    V2BadRequest:
      description: Invalid or incomplete request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/V2Envelope'
          example:
            status: 400
            status_message: Requisição incompleta
            data: null
    V2Unauthorized:
      description: Invalid token
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/V2Envelope'
          example:
            status: 401
            status_message: Token inválido
            data: null
  securitySchemes:
    securityTokenQuery:
      type: apiKey
      in: query
      name: userSecurityToken
      description: >-
        Your account security token, sent as the `userSecurityToken` query or
        form parameter.

````