get_client_subscription_status
GET /client_subscriptions/status
Get the subscription status of a responder (client), identified by their phone number or their email
- Rails
- cURL
require 'rest-client'
RestClient::Request.execute method: :get,
url: 'https://api.diduenjoy.com/api/v1/client_subscriptions/status?email=client@example.com',
user: 'PUT-YOUR-API-KEY-HERE'
# => {
# "status": "subscribed"
# }
---------------Filter[phone_number]--------------------------
require 'rest-client'
RestClient::Request.execute method: :get,
url: 'https://api.diduenjoy.com/api/v1/client_subscriptions/status?phone_number=%2B33612345678',
user: 'PUT-YOUR-API-KEY-HERE'
curl 'https://api.diduenjoy.com/api/v1/client_subscriptions/status?email=client@example.com' \
-u 'PUT-YOUR-API-KEY-HERE:'
# => {
# "status": "subscribed"
# }
---------------Filter[phone_number]--------------------------
curl 'https://api.diduenjoy.com/api/v1/client_subscriptions/status?phone_number=%2B33612345678' \
-u 'PUT-YOUR-API-KEY-HERE:'
attributes
| attribute | description |
|---|---|
| status string | current subscription status of the client for your company. Returns subscribed when the client has no subscription record yet. |
required parameters (one of the two)
| parameter | description |
|---|---|
| email string | the client's email |
| phone_number string | the client's phone number, international format recommended (ex: +33) |
note
You SHALL provide exactly one of email or phone_number, not both.
errors
| status | description |
|---|---|
| 422 unprocessable_content | neither phone_number nor email was provided |
| 422 unprocessable_content | both phone_number and email were provided |