curl --request POST \
--url https://dev-public-api.openphone.dev/v1/messages \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"content": "<string>",
"from": "+15555555555",
"to": [
"+15555555555"
],
"phoneNumberId": "OP1232abc",
"userId": "US123abc",
"setInboxStatus": "done"
}
'{
"data": {
"id": "AC123abc",
"to": [
"+15555555555"
],
"from": "+15555555555",
"text": "Hello, world!",
"phoneNumberId": "PN123abc",
"conversationId": "CN123abc",
"direction": "incoming",
"userId": "US123abc",
"status": "sent",
"createdAt": "2022-01-01T00:00:00Z",
"updatedAt": "2022-01-01T00:00:00Z",
"media": [
{
"url": "https://example.com/image.png",
"type": "image/png"
}
]
}
}{
"message": "<string>",
"code": "0206400",
"status": 400,
"docs": "https://quo.com/docs",
"title": "A2P Registration Not Approved",
"description": "A2P Registration Not Approved",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}{
"message": "<string>",
"code": "0200401",
"status": 401,
"docs": "https://quo.com/docs",
"title": "Unauthorized",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}{
"message": "<string>",
"code": "0201402",
"status": 402,
"docs": "https://quo.com/docs",
"title": "Subscription Expired",
"description": "Your subscription has expired",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}{
"message": "<string>",
"code": "0204403",
"status": 403,
"docs": "https://quo.com/docs",
"title": "A2P 10DLC Daily Message Cap Reached",
"description": "A2P 10DLC Daily limit reached. For help increasing this limit, visit https://support.quo.com/help/submit-a-request",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}{
"message": "<string>",
"code": "0200404",
"status": 404,
"docs": "https://quo.com/docs",
"title": "Not Found",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}{
"message": "<string>",
"code": "0201500",
"status": 500,
"docs": "https://quo.com/docs",
"title": "Unknown",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}Send a text message
Send a text message from your Quo number to a recipient.
curl --request POST \
--url https://dev-public-api.openphone.dev/v1/messages \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"content": "<string>",
"from": "+15555555555",
"to": [
"+15555555555"
],
"phoneNumberId": "OP1232abc",
"userId": "US123abc",
"setInboxStatus": "done"
}
'{
"data": {
"id": "AC123abc",
"to": [
"+15555555555"
],
"from": "+15555555555",
"text": "Hello, world!",
"phoneNumberId": "PN123abc",
"conversationId": "CN123abc",
"direction": "incoming",
"userId": "US123abc",
"status": "sent",
"createdAt": "2022-01-01T00:00:00Z",
"updatedAt": "2022-01-01T00:00:00Z",
"media": [
{
"url": "https://example.com/image.png",
"type": "image/png"
}
]
}
}{
"message": "<string>",
"code": "0206400",
"status": 400,
"docs": "https://quo.com/docs",
"title": "A2P Registration Not Approved",
"description": "A2P Registration Not Approved",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}{
"message": "<string>",
"code": "0200401",
"status": 401,
"docs": "https://quo.com/docs",
"title": "Unauthorized",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}{
"message": "<string>",
"code": "0201402",
"status": 402,
"docs": "https://quo.com/docs",
"title": "Subscription Expired",
"description": "Your subscription has expired",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}{
"message": "<string>",
"code": "0204403",
"status": 403,
"docs": "https://quo.com/docs",
"title": "A2P 10DLC Daily Message Cap Reached",
"description": "A2P 10DLC Daily limit reached. For help increasing this limit, visit https://support.quo.com/help/submit-a-request",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}{
"message": "<string>",
"code": "0200404",
"status": 404,
"docs": "https://quo.com/docs",
"title": "Not Found",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}{
"message": "<string>",
"code": "0201500",
"status": 500,
"docs": "https://quo.com/docs",
"title": "Unknown",
"trace": "<string>",
"errors": [
{
"path": "<string>",
"message": "<string>",
"schema": {
"type": "<string>"
},
"value": "<unknown>"
}
]
}Authorizations
Body
The text content of the message to be sent.
1 - 1600.*\S.*The sender's phone number. Can be either your Quo phone number ID or the full phone number in E.164 format.
^PN(.*)$"+15555555555"
Array of recipient phone numbers in E.164 format. Currently supports a maximum of 10 recipients
1 - 10 elementsA phone number in E.164 format, including the country code.
^\+[1-9]\d{1,14}$"+15555555555"
["+15555555555"]
DEPRECATED, use "from" instead. Quo phone number ID to send a message from
^PN(.*)$"OP1232abc"
The unique identifier of the Quo user sending the message. If not provided, the message is attributed to the owner of the phone number it is sent from. The sending user must be a member of the phone number the message is sent from.
^US(.*)$"US123abc"
Used to set the status of the related Quo inbox conversation. The default behavior without setting this parameter will be for the message sent to show up as an open conversation in the user's inbox. Setting the parameter to 'done' would move the conversation to the Done inbox view.
done "done"
Response
Accepted
Show child attributes
Show child attributes
Was this page helpful?