Upsert
Upserts a web push subscription for the user
Path parameters
-
user_id
string Required
Body
Required
-
endpoint
string Required Minimum length is
10
, maximum length is1024
. -
expirationTime
string | null -
keys
object | null
POST
/api/users/{user_id}/web_push_subscriptions
curl \
-X POST https://metropolitanabogota.org/api/users/{user_id}/web_push_subscriptions \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"endpoint":"string","expirationTime":"string","keys":{}}'
Request example
{
"endpoint": "string",
"expirationTime": "string",
"keys": {}
}
Response examples (422)
{
"detail": [
{
"loc": [
"string"
],
"msg": "string",
"type": "string"
}
]
}