Subscriptions

To keep track of users' participation within various campaigns, we use subscriptions. Before a user can participate in a campaign, they must first subscribe to the campaign.

The subscription object

This object represents the subscription of a user to a campaign.

Create subscription

Create a new subscription for the given user

post
Authorizations
Path parameters
campaignIdstringRequired
Body
userany ofRequired
or
or
Responses
200
accepted
application/json
post
POST /v1/campaigns/{campaignId}/subscriptions HTTP/1.1
Host: localhost:8080
Authorization: Bearer YOUR_OAUTH2_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 35

{
  "user": {
    "email": "name@gmail.com"
  }
}
{
  "subscriptionId": "text"
}

Retrieve subscription

get

Get subscription state for a user, including incentives completion

Authorizations
Path parameters
userIdstringRequired
Query parameters
identifierTypestring · enumRequiredPossible values:
Responses
200
Ok
application/json
get
GET /v1/campaigns/{campaignId}/subscriptions/{userId} HTTP/1.1
Host: localhost:8080
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*
200

Ok

{
  "createdAt": "2025-07-05",
  "incentives": [
    {
      "id": "text",
      "status": "VERIFIED",
      "reward": 1,
      "createdAt": "2025-07-05"
    }
  ]
}

Last updated