MobiariDocs
Admin APINotifications

Set a member's team alerts

PUT
/stores/{store_id}/alert-subscriptions/{user_id}

Which sale alerts a member of the store gets on WhatsApp. Members without a profile phone are skipped at send time.

Authorization

bearer_auth
AuthorizationBearer <token>

Authorization: Bearer <token>. Either a session access token from POST /auth/login (refresh it with POST /auth/refresh) or a store API token (mobi_st_…). A store API token works only for the store it was issued in, and can do at most what its issuing user can there, narrowed to the scopes it was issued with.

In: header

Path Parameters

store_id*string

Store id

Formatuuid
user_id*string

The member's user id

Formatuuid

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X PUT "https://example.com/stores/497f6eca-6276-4993-bfeb-53cbbbba6f08/alert-subscriptions/497f6eca-6276-4993-bfeb-53cbbbba6f08" \  -H "Content-Type: application/json" \  -d '{    "enabled_events": [      "orders.paid"    ]  }'
{
  "email": "string",
  "enabled_events": [
    "orders.paid"
  ],
  "has_phone": true,
  "is_enabled": true,
  "name": "string",
  "user_id": "a169451c-8525-4352-b8ca-070dd449a1a5"
}
{
  "code": "not_found",
  "details": {},
  "error": "Order not found"
}
{
  "code": "not_found",
  "details": {},
  "error": "Order not found"
}
{
  "code": "not_found",
  "details": {},
  "error": "Order not found"
}
{
  "code": "not_found",
  "details": {},
  "error": "Order not found"
}
{
  "code": "not_found",
  "details": {},
  "error": "Order not found"
}