Update a price

Updates a price by the given id.

put
Path parameters
idstringRequired

The id of the price.

Header parameters
Brand-URLstringRequired

The brand URL of the request. This is used to identify the brand.

Example: YOUR_BRAND_URL
Auth-KeystringRequired

This is used to authenticate the request. If the request is not authenticated, the server will return a 401 Unauthorized response.

Example: YOUR_AUTH_KEY
Body

This class presents the Price Command Request Data from the client.

packageIdstring · min: 1Required

The id of the package.

subscriptionTypeIdstring · min: 1Required

The id of the subscription type

codestring · min: 1Required

The code of the price.

namestring · min: 1Required

The name of the price.

amountnumber · doubleRequired

The amount of the price.

currencystring · min: 1Required

The currency code of the price. The currency must be a valid ISO 4217 currency code.

checkoutLinkstring · uri | nullableOptional

The checkout link of the price. When the user clicks on this link, they will be redirected to the checkout page.

descriptionstring | nullableOptional

The description of the price.

tagsstring | nullableOptional

The tags of the price.

zOrderinteger · int32 | nullableOptional

The order of the price. This value is used to sort into the list of prices. By default, the value is 1. If you want to change the order of the price, you can set this value to a higher number.

Responses
200
The request was successful.
application/json
put
PUT /api/v1/prices/{id} HTTP/1.1
Host: protocol.jframework.io
Brand-URL: text
Auth-Key: text
Content-Type: application/json
Accept: */*
Content-Length: 188

{
  "packageId": "text",
  "subscriptionTypeId": "text",
  "code": "text",
  "name": "text",
  "amount": 1,
  "currency": "text",
  "checkoutLink": "https://example.com",
  "description": "text",
  "tags": "text",
  "zOrder": 1
}
{
  "success": true,
  "statusCode": 200,
  "message": "The request was successful.",
  "data": {
    "id": "sApKpllz4sAplsmzha",
    "code": "Code",
    "name": "Name",
    "amount": 10,
    "currency": "USD",
    "description": "Description",
    "checkoutLink": "CheckoutLink",
    "tags": "Tags",
    "packageName": "PackageName",
    "packageId": "PackageId",
    "subscriptionName": "SubscriptionName",
    "subscriptionTypeId": "SubscriptionTypeId",
    "zOrder": 1
  },
  "errors": []
}

Last updated

Was this helpful?