API ReferenceAdmin Products
Publish
Authorization
AdminSession AuthorizationBearer <token>
Admin session token returned by POST /auth/login, sent as 'Authorization: Bearer '.
In: header
Path Parameters
id*integer
Response Body
*/*
curl -X POST "https://example.com/api/v1/admin/products/0/publish"{
"data": {
"id": 0,
"name": "string",
"description": "string",
"status": "DRAFT",
"mode": "TEST",
"prices": [
{
"id": 0,
"productId": 0,
"type": "ONE_TIME",
"amountMinor": 0,
"currency": "string",
"interval": "DAY",
"intervalCount": 0,
"trialDays": 0,
"active": true,
"createdAt": "2019-08-24T14:15:22Z"
}
],
"benefits": [
{
"id": 0,
"lookupKey": "string",
"name": "string",
"metadata": "string",
"active": true,
"mode": "TEST",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}
],
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
},
"meta": {
"success": true,
"message": "string",
"errorCode": "RESOURCE_NOT_FOUND",
"timestamp": "2019-08-24T14:15:22Z"
},
"pagination": {
"page": 0,
"size": 0,
"totalElements": 0,
"totalPages": 0
}
}