# Google Cloud Confidential Computing V1 Client - Class CreateChallengeRequest (1.7.1)

1.7.1 (latest) 1.7.0 1.6.2 1.5.0 1.4.1 1.3.0 1.2.2 1.1.1 1.0.0 0.8.3 0.7.0 0.6.0 0.5.1 0.4.0 0.3.0 0.2.2 0.1.1 Reference documentation and code samples for the Google Cloud Confidential Computing V1 Client class CreateChallengeRequest.

Message for creating a Challenge

Generated from protobuf message `google.cloud.confidentialcomputing.v1.CreateChallengeRequest`

## Namespace

Google \\ Cloud \\ ConfidentialComputing \\ V1

## Methods

### __construct

Constructor.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `data` | `mixed` |

### getParent

Required. The resource name of the location where the Challenge will be
used, in the format `projects/*/locations/*`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setParent

Required. The resource name of the location where the Challenge will be
used, in the format `projects/*/locations/*`.

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

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

### getChallenge

Required. The Challenge to be created. Currently this field can be empty as
all the Challenge fields are set by the server.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-confidentialcomputing/latest/V1.Challenge|null` |   |

### hasChallenge

### clearChallenge

### setChallenge

Required. The Challenge to be created. Currently this field can be empty as
all the Challenge fields are set by the server.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-confidentialcomputing/latest/V1.Challenge` |

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

### static::build

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `string` Required. The resource name of the location where the Challenge will be used, in the format `projects/*/locations/*`. Please see ConfidentialComputingClient::locationName() for help formatting this field. |
| `challenge` | `https://docs.cloud.google.com/php/docs/reference/cloud-confidentialcomputing/latest/V1.Challenge` Required. The Challenge to be created. Currently this field can be empty as all the Challenge fields are set by the server. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-confidentialcomputing/latest/V1.CreateChallengeRequest` |   |