Notification Pusher API (1.0.0)

Push notification to clients.

Notification

Push bulk notifications.

Authorizations:
bearerAuth
Request Body schema: application/json
Array of objects

Responses

Request samples

Content type
application/json
{
  • "events": [
    ]
}

Response samples

Content type
application/json
{
  • "code": "success",
  • "message": "Successfully bulk pushed notifications",
  • "server_time": "2021-05-20T12:38:03.851056Z"
}

Get notification

Only sysadmin & merchant can access this endpoint

For any link to s3, please use get detail notification instead to get signed url

Authorizations:
bearerAuth
query Parameters
order
string
Default: "desc"
Enum: "asc" "desc"

The direction of the sort

range_start_created_at
string
Example: range_start_created_at=2022-01-03T15:04:05Z

Range start (inclusive) of Created At

range_end_created_at
string
Example: range_end_created_at=2025-01-03T15:04:05Z

Range end (inclusive) of Created At

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "notifications": [
    ]
}

Read notification.

Only sysadmin & merchant can access this endpoint. Set notification as has been read.

*is_read from false to true

Authorizations:
bearerAuth

Responses

Response samples

Content type
application/json
{
  • "message": "Successfully update notification as has been read",
  • "server_time": "2021-05-20T12:38:03.851056Z"
}

Get detail notification

Read an existing Notification log detail.

Authorizations:
bearerAuth
path Parameters
notification_id
required
string

ID of the Notification log to be read.

Responses

Response samples

Content type
application/json
{
  • "event_type": "string",
  • "event_data": {
    }
}

Push notifications.

Pushed notifications and create a log in notification log db

Authorizations:
bearerAuth
Request Body schema: application/json
event_type
string
object

Responses

Request samples

Content type
application/json
{
  • "event_type": "string",
  • "event_data": {
    }
}

Response samples

Content type
application/json
{
  • "server_time": "2021-05-20T12:38:03.851056Z"
}

Push Notification Key

Push bulk push notifications.

Authorizations:
bearerAuth
Request Body schema: application/json
Array of objects
application_key
string
org_id
string

Responses

Request samples

Content type
application/json
{
  • "push_messages": [
    ],
  • "application_key": "string",
  • "org_id": "string"
}

Response samples

Content type
application/json
{
  • "code": "success",
  • "message": "Successfully bulk pushed push notifications",
  • "server_time": "2021-05-20T12:38:03.851056Z"
}

Get push notification key list

Only sysadmin, RRTB, Price Adjustment can access this endpoint

Authorizations:
bearerAuth
query Parameters
order
string
Default: "desc"
Enum: "asc" "desc"

The direction of the sort

page
integer <int64> >= 1
Default: 1
per_page
integer <int64> >= 1
Default: 200
application_key
string

filter by application key

is_qa
boolean

Is Quality Assurance

range_start_created_at
string
Example: range_start_created_at=2022-01-03T15:04:05Z

Range start (inclusive) of Created At

range_end_created_at
string
Example: range_end_created_at=2025-01-03T15:04:05Z

Range end (inclusive) of Created At

Responses

Response samples

Content type
application/json
{
  • "meta": {
    },
  • "push_notifications": [
    ]
}

Store new push notification key

Authorizations:
bearerAuth
Request Body schema: application/json
device_id
string
application_key
string
org_id
string
user_id
string
push_notification_key
string

Responses

Request samples

Content type
application/json
{
  • "device_id": "string",
  • "application_key": "string",
  • "org_id": "string",
  • "user_id": "string",
  • "push_notification_key": "string"
}

Response samples

Content type
application/json
{
  • "code": "success",
  • "message": "Successfully add push notification key",
  • "server_time": "2021-05-20T12:38:03.851056Z"
}

Remove push notification keys by user & device ID.

Only OrgDriver & OrgTransporter are allowed to call this API

Authorizations:
bearerAuth

Responses

Response samples

Content type
application/json
{
  • "code": "success",
  • "message": "Successfully remove push notification keys",
  • "server_time": "2021-09-23T15:47:26.699327+08:00"
}

Remove push notification keys by user (delete account).

Only OrgDriver & OrgTransporter are allowed to call this API

Authorizations:
bearerAuth

Responses

Response samples

Content type
application/json
{
  • "code": "success",
  • "message": "Successfully remove push notification keys",
  • "server_time": "2021-09-23T15:47:26.699327+08:00"
}