templates

Cria e submete um template à Twilio/Meta para aprovação

Requer conta ACTIVE (live mode). Plano FREE limitado a 3 templates. Submete pra Twilio; status inicial fica PENDING. Use /v1/templates/{id}/status pra checar aprovação.

post/v1/templates

Request body

namestring required
category'MARKETING' | 'UTILITY' | 'AUTHENTICATION' required
bodystring required
languagestring
headerstring nullable
headerType'text' | 'media' | 'document' nullable
footerstring nullable
samplesobject nullable
variableExamplesstring[] nullable
otpButtonType'COPY_CODE' | 'ONE_TAP' nullable
otpPackageNamestring nullable
otpAppSignaturestring nullable

Response

Template criado e submetido

idstring uuid required
namestring required
formattedNamestring required
categorystring required
originalCategorystring nullable
languagestring required
providerNamestring required
providerTemplateIdstring required
providerStatusstring required
rejectionReasonstring nullable
bodyPreviewstring nullable
structureJsonobject required
usageGuideobject nullable
variablesSchemaobject nullable
createdAtstring date-time required
updatedAtstring date-time nullable

Example response

{
  "providerStatus": "APPROVED"
}

Changes

Changed in 1 of the 4 revisions of this API.629

  • 4e426b85f784629See the full diff
    • the response property bodyPreview became nullable for the status 201

      response-property-became-nullable

    • the response property originalCategory became nullable for the status 201

      response-property-became-nullable

    • the response property rejectionReason became nullable for the status 201

      response-property-became-nullable

    • the response property updatedAt became nullable for the status 201

      response-property-became-nullable

    • the response property usageGuide became nullable for the status 201

      response-property-became-nullable

    • the response property variablesSchema became nullable for the status 201

      response-property-became-nullable

    • api tag templates added

      api-tag-added

    • api tag Templates removed

      api-tag-removed

    • added the new optional request property carouselCards

      new-optional-request-property

    • added the new optional request property headerType

      new-optional-request-property

    • added the new optional request property otpAppSignature

      new-optional-request-property

    • added the new optional request property otpButtonType

      new-optional-request-property

    • added the new optional request property otpPackageName

      new-optional-request-property

    • the request property buttons became nullable

      request-property-became-nullable

    • the request property buttons/items/extraConfig became nullable

      request-property-became-nullable

    • the request property buttons/items/phone became nullable

      request-property-became-nullable

    • the request property buttons/items/url became nullable

      request-property-became-nullable

    • the request property footer became nullable

      request-property-became-nullable

    • the request property header became nullable

      request-property-became-nullable

    • the request property samples became nullable

      request-property-became-nullable

    • the request property variableExamples became nullable

      request-property-became-nullable

    • added the media type application/json for the response with the status 400

      response-media-type-added

    • added the media type application/json for the response with the status 401

      response-media-type-added

    • added the non-success response with the status 403

      response-non-success-status-added

    • added the non-success response with the status 422

      response-non-success-status-added

    • the response property category became required for the status 201

      response-property-became-required

    • the response property createdAt became required for the status 201

      response-property-became-required

    • the response property formattedName became required for the status 201

      response-property-became-required

    • the response property id became required for the status 201

      response-property-became-required

    • the response property language became required for the status 201

      response-property-became-required

    • the response property name became required for the status 201

      response-property-became-required

    • the response property providerName became required for the status 201

      response-property-became-required

    • the response property providerStatus became required for the status 201

      response-property-became-required

    • the response property providerTemplateId became required for the status 201

      response-property-became-required

    • the response property structureJson became required for the status 201

      response-property-became-required

    This revision also has 24 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog