Query Auto Renewal Status

Check if automatic renewal is enabled for an existing product.

Request URL

GET {base_url}/order/openapi/order/v1/check/existed_auto_renew?{query parameters}

Request parameters

Headers
Parameter Required Description
User-Agent Yes Provide information about the user agent, such as the type of web browser, operating system, software version, etc., so as to help Yeastar Partner Portal to identify the user or the application that is making the request.

Example: User-Agent: OpenAPI.

Authorization Yes Pass the access token in the header, so as to authenticate the API request.

Format: Bearer {access_token}.

Query parameters
Parameter Required Type Description
productNo Yes String The unique product identifier.

Valid value: The Serial Number (SN) of the PBX.

Note: You can query this information using the Query Product List interface.
productId Yes Integer The unique ID of the product.
Note: You can query product ID using the Query Available Subscription Products interface.

Response parameters

Parameter Type Description
code String The response message of the API request.
detailMessage String The detailed error information.

When the request is successful, this parameter returns empty.

requestId String The unique ID of the request, which can be used to quickly locate the request.
result Object<Details> The detailed auto renewal information.
status Integer The HTTP status code of the API request.
Details
Parameter Type Description
autoRenew Boolean Whether auto renewal is enabled or not for the product.
  • true: Enabled.
  • false: Disabled.

Example

Request example

Query the auto renewal status of a P-Series Software Edition.

GET /order/openapi/order/v1/check/existed_auto_renew?productNo=3651xxxx9415&productId=12 HTTP/1.1
Host: openapi.partner.yeastar.com
User-Agent: OpenAPI
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOlsicmVzMSJdLCJYLU1TLVVTRVIiOiJ7XCJleHByXCI6XCIwXCIsXCJ0eXBlXCI6XCJwYXJ0bmVyXCIsXCJ1Y0lkXCI6XCIzMDc2OTE1NDU0NDY4NzY3NzQ0XCIsXCJ1c2VyQ29kZVwiOlwiUGFydG5lclwiLFwidXNlcklkXCI6XCIzMDc2OTE1NDU0NDg5NzM5MjY0XCIsXCJ1c2VybmFtZVwiOlwicGFydG5lcmV4YW1wbGVAb3V0bG9vay5jb21cIn0iLCJ1c2VyX25hbWUiOiJwYXJ0bmVyZXhhbXBsZUBvdXRsb29rLmNvbSIsInNjb3BlIjpbImFsbCJdLCJleHAiOjE3Mzk2MjgzNTksInRva2VuX3R5cGUiOiJvcGVuYXBpIiwianRpIjoidjY3ZlJzM2FDVXNDa2dQTWg0RmlxUG9wYWRNPSIsImF1dGhvcml0aWVzIjpbIjc5Il0sImNsaWVudF9pZCI6IjE0NDI5NjM2ODBiMjM0YjA0YmRjZDVjMTZmODcyOWQ2In0.ScdMGZU9NnFGyuagRGaTfnOBBb7R6ThPMamcdtqpr1o

Response example

{
    "code": "success",
    "detailMessage": "",
    "requestId": "4078a99a6f6741d448768148d3e703e0",
    "result": {
        "autoRenew": true     //Auto renewal is enabled
    },
    "status": 200
}