The WhatsApp endpoint allows you to programmatically log in to and get details of your WhatsApp account.
Enable Meta template analytics for WhatsApp Business Account.
projectId required | string The unique ID of the project. You can find this on the Sinch Dashboard. |
Meta template analytics enabled for WhatsApp Business Account.
BadRequest
Unauthorized
FailedDependency
InternalServerError
{- "errorCode": "project_not_initialized",
- "message": "Project not initialized for WhatsApp.",
- "resolution": "Verify that the project ID is correct and that it has been onboarded for WhatsApp."
}
Returns a long lived access token based on the facebook token from the embedded signup. Valid for 60 days.
projectId required | string The unique ID of the project. You can find this on the Sinch Dashboard. |
Facebook token generated from the embedded signup process, or another long lived access token.
Example body request to create a long lived access token.
{- "facebookCode": "FACEBOOK_CODE"
}
Response when successfully creating a long lived access token.
{- "longLivedAccessToken": "FACEBOOK_TOKEN"
}
Returns a list of all the WhatsApp Business Accounts that the facebook token is associated with, together with the numbers that are shared.
projectId required | string The unique ID of the project. You can find this on the Sinch Dashboard. |
WabaDetails data with Facebook token generated from the embedded signup process.
List of WhatsApp Business Accounts.
BadRequest
Unauthorized
InternalServerError
Example body request to list WhatsApp Business Accounts details.
{- "facebookToken": "FACEBOOK_TOKEN"
}
Response for all waba details.
{- "wabas": [
- {
- "id": "100000000000000",
- "name": "Example company",
- "numbers": [
- {
- "id": "222222222222222",
- "displayPhoneNumber": "+48 777 777777",
- "provisioned": false
}
]
}
]
}