# Trigger renewal before usage upload interval

Trigger the renewal for a pay-per-usage subscription even before the end of the usage upload interval. Once the API call is made, the subscription is marked as ready to renew, and a renewal will be attempted. If the first attempt is not successful, the renewal of the subscription will be attempted again based on the regular renewal schedule.

## Request parameters

| Parameter             | Type   | Required | Description                                                                                                                                                                                                                                                                                                                                                                          |
| --------------------- | ------ | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| sessionID             | String | Required | Session identifier, the output of the **Login** method. Include **sessionID** into all your requests. 2Checkout throws an exception if the values are incorrect. The sessionID expires in 10 minutes.                                                                                                                                                                                |
| subscriptionReference | String | Required | Unique, system-generated subscription identifier. 2Checkout charges customers using the payment data attached to subscriptions. In the case of credit/debit cards, if customers update their payment information in MyAccount or if you update these details on behalf of your subscribers, the 2Checkout system uses the latest card info provided to charge subscription renewals. |

### Request sample

```php
<?php

require ('PATH_TO_AUTH');

$subscriptionReference = 'YOUR_SUBSCRIPTION_REFERENCE';

try {
    $success = $client->markUsageSubscriptionToRenewNow($sessionID, $subscriptionReference, $Days, $Price, $Currency);
}
catch (SoapFault $e) {
    echo "Fault: " . $e->getMessage();
    exit;
}
var_dump("Success", $success);
```

## Response parameters

| Type        | Description                                                                                                                                                             |
| ----------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Boolean** | **true** or **false** depending on whether or not the subscription was marked as ready to be renewed. The response does not reflect the success of the renewal attempt. |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.2checkout.com/soap-api-reference/soap-api-6.0/api-requests/usage-management/trigger-renewal-before-usage-upload-interval.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
