PATCH/partners/customers/{domainId}/usage-status

Sets the maximum number of users (maxMemberCount) or a scheduled cancellation date (withdrawalDate).

  • Set the maximum number of users (maxMemberCount)

    • Any previously scheduled task to set the maximum number of users will be deleted if this API operation is used.
  • Set a scheduled cancellation date (withdrawalDate)

    • This API operation cannot set a scheduled cancellation date for a partner domain.
    • The customer will be billed on the next invoice for the services used up to the scheduled cancellation date (withdrawalDate), along with any penalty charges. To cancel the subscription without penalties, set the withdrawalDate to the day after the subscription ends.
    • When the scheduled cancellation date (withdrawalDate) is reached:
      • For customers who have installed paid apps that do not allow real-time billing
        • If the customer’s subscription is pending cancellation, the status of Get usage status becomes SUSPENDED_WITHDRAWAL, and the subscription will be deleted (canceled) on the withdrawalDate of Get usage status.
        • If the scheduled cancellation date is set to apply between the 2nd and 24th, the last billing day will be the 1st day of the following month, and the subscription will be canceled on the 2nd day of the following month.
      • If the customer has not installed paid apps that do not allow real-time billing, the customer’s subscription will be deleted (canceled).
      • Paid apps that do not support real-time billing include:
        • Delivery service (Yamato Transport)

Authorization

oauth2

OAuth 2.0 authentication. For more information, see Authentication and Authorization.

Scope

partner

HTTP Request

PATCHhttps://www.worksapis.com/v1.0/partners/customers/{domainId}/usage-status

Path Parameters

ParameterTypeDescription
domainId integer 

Domain ID


required
example : 10000001 

Header Parameters

HeadertypeDescription
Authorization string 

Bearer {token}


required 

Request Body

PropertyTypeDescription
maxMemberCount integer 

Maximum number of users to apply

  • If it is null, no limits apply.

nullable : true 
withdrawalDate string 

Scheduled cancellation date.

  • If it is null, the scheduled task to cancel the subscription is deleted.
  • The date can range up to 1 year later.

format : date
nullable : true 

Request Example

Set the maximum number of users to 10, and the scheduled cancellation date to 2025-12-31

1{2  "maxMemberCount": 10,3  "withdrawalDate": "2025-12-31"4}

Delete the scheduled cancellation and set the maximum number of users to 10

1{2  "maxMemberCount": 10,3  "withdrawalDate": null4}

Delete the maximum number of users and the scheduled cancellation

1{2  "maxMemberCount": null,3  "withdrawalDate": null4}

Set the scheduled cancellation date to 2025-12-31 and delete the setting of the maximum number of users

1{2  "maxMemberCount": null,3  "withdrawalDate": "2025-12-31"4}

Response

HTTP 200

OK

PropertyTypeDescription
domainId integer 

Domain ID

 
status string 

Customer status

  • ACTIVE: Active
  • SUSPENDED_ADMIN: Suspended (by the administrator)
  • SUSPENDED_WITHDRAWAL: Suspended (pending cancellation)

Allowed values : ACTIVE, SUSPENDED_ADMIN, SUSPENDED_WITHDRAWAL 
memberCount integer 

Number of users

 
maxMemberCount integer 

Maximum number of users


nullable : true 
withdrawalDate string 

Cancellation date

  • It is the date when the customer’s subscription is deleted (canceled) if the status is SUSPENDED_WITHDRAWAL.
  • Otherwise, it is null.

format : date
nullable : true 
renewal object (renewal) 

Scheduled subscription information

 

renewal

PropertyTypeDescription
maxMemberCount integer 

Maximum number of users


nullable : true 
applyDate string 

Scheduled date


required
format : date 

Response Example

Example 1

1{2  "domainId": 0,3  "status": "ACTIVE",4  "memberCount": 0,5  "maxMemberCount": 0,6  "withdrawalDate": "2019-08-24"7}