Store The Text Message Templates

From docs
Revision as of 06:45, 21 July 2026 by Ashley DeBon (talk | contribs) (Add Text Message Template)
Jump to: navigation, search

Mobile_API »Add Text Message Template

Base URL

https://apimobile.callproof.com

Endpoint

/api/text-message-templates

Purpose

Creates a new SMS/text message template for the authenticated user. The template title is optional; if omitted, a default title is used.

HTTP Method

POST

Headers

Header Required Description
Authorization Yes Bearer access token

Security

  • Yes – Requires Bearer Token authentication.

Parameters

Path Parameters

None.

Query Parameters

None.

Request Body

Parameter Type Required Description
message string Yes Template message body (commas in the message are stored as spaces)
title string No Template title (defaults to Title when omitted)

Successful Response (200)

Indicates that the text message template was created successfully.

Field Type Description
clientStatusCode integer Status indicator for the client (for example, 200)
user_id integer Identifier of the authenticated user
company_id integer Identifier of the authenticated user’s company
message string Confirmation message (for example, "The text message templates details added successfully.")
uri string Requested resource URI

Error Responses

Status Code Meaning
200 Validation failed – response body uses clientStatusCode 401 with the first validation error message
400 Bad Request – the template could not be created
401 Unauthorized – missing, invalid, or expired Bearer token
  • Validation (HTTP 200, clientStatusCode 401) – Missing message.
  • 400 – An error occurred while creating the template (for example, "Error while retrieving the text message template details").
  • 401 – Authentication failed or the access token is missing/expired.