Logo
Get supportSee a Demo
HomeAPI Reference
HomeAPI Reference
    • Getting Started
    • Authentication
    • Usage Quotas
    • Notifications
    • Attributions
  • API Reference
Get supportSee a Demo
API ReferenceAttributions

POST
/v2/issuers/:organizationId/users/:userId/attributions
POST
/v2/issuers/:organizationId/users/:userId/attributions
1curl -X POST https://rewards-api.getkard.com/v2/issuers/organization-123/users/user-123/attributions \
2 -H "Authorization: Bearer <token>" \
3 -H "Content-Type: application/json" \
4 -d '{
5 "data": [
6 {
7 "type": "offerAttribution",
8 "attributes": {
9 "entityId": "60e4ba1da31c5a22a144c075",
10 "eventCode": "VIEW",
11 "medium": "SEARCH",
12 "eventDate": "2025-01-01T00:00:00Z"
13 }
14 },
15 {
16 "type": "offerAttribution",
17 "attributes": {
18 "entityId": "60e4ba1da31c5a22a144c077",
19 "eventCode": "IMPRESSION",
20 "medium": "EMAIL",
21 "eventDate": "2025-01-01T00:00:00Z"
22 }
23 },
24 {
25 "type": "notificationAttribution",
26 "attributes": {
27 "entityId": "60e4ba1da31c5a22a144c076",
28 "eventCode": "IMPRESSION",
29 "medium": "PUSH",
30 "eventDate": "2025-01-01T00:00:00Z"
31 }
32 }
33 ]
34}'
Try it
1{
2 "data": {
3 "type": "job",
4 "id": "c94a93a7-beb9-4e58-960c-2c812f849398",
5 "attributes": {
6 "status": "queued",
7 "message": "Attribution events are queued for processing"
8 }
9 }
10}
Was this page helpful?
Previous

Get Files

Next
Built with
Call this endpoint to send attribution events made by a single enrolled user for processing. A maximum of 100 events can be included in a single request. <b>Required scopes:</b> `attributions:write`
Create Attribution Events

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

organizationIdstringRequired
Your issuer organization ID, provided by Kard
userIdstringRequired
The ID of the user as defined on the issuers system

Request

This endpoint expects an object.
datalist of objectsRequired
Discriminated union representing the request body for submitting attribution events. Use `type` to distinguish between the two: - `offerAttribution`: Events related to viewing or interacting with an offer. - `notificationAttribution`: Events related to viewing or interacting with a notification.

Response

This endpoint returns an object.
dataobject

Errors

Call this endpoint to send attribution events made by a single enrolled user for processing. A maximum of 100 events can be included in a single request.

Required scopes: attributions:write

Discriminated union representing the request body for submitting attribution events. Use type to distinguish between the two:

  • offerAttribution: Events related to viewing or interacting with an offer.
  • notificationAttribution: Events related to viewing or interacting with a notification.