# Google Cloud Commerce Consumer Procurement V1 Client - Class Subscription (1.3.3)

1.3.3 (latest) 1.3.2 1.2.2 1.1.3 1.0.0 0.2.5 0.1.1 Reference documentation and code samples for the Google Cloud Commerce Consumer Procurement V1 Client class Subscription.

Subscription information.

Generated from protobuf message `google.cloud.commerce.consumer.procurement.v1.Subscription`

## Namespace

Google \\ Cloud \\ Commerce \\ Consumer \\ Procurement \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ start_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` The timestamp when the subscription begins, if applicable. |
| `↳ end_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` The timestamp when the subscription ends, if applicable. |
| `↳ auto_renewal_enabled` | `bool` Whether auto renewal is enabled by user choice on current subscription. This field indicates order/subscription status after pending plan change is cancelled or rejected. |

### getStartTime

The timestamp when the subscription begins, if applicable.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp|null` |   |

### hasStartTime

### clearStartTime

### setStartTime

The timestamp when the subscription begins, if applicable.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getEndTime

The timestamp when the subscription ends, if applicable.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp|null` |   |

### hasEndTime

### clearEndTime

### setEndTime

The timestamp when the subscription ends, if applicable.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAutoRenewalEnabled

Whether auto renewal is enabled by user choice on current subscription.

This field indicates order/subscription status after pending plan change is
cancelled or rejected.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### setAutoRenewalEnabled

Whether auto renewal is enabled by user choice on current subscription.

This field indicates order/subscription status after pending plan change is
cancelled or rejected.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |