# Google Cloud Functions V2 Client - Class GenerateUploadUrlResponse (2.1.3)

2.1.3 (latest) 2.1.2 2.0.6 1.7.0 1.6.5 1.5.0 1.4.2 1.3.1 1.2.0 1.1.2 1.0.3 Reference documentation and code samples for the Google Cloud Functions V2 Client class GenerateUploadUrlResponse.

Response of `GenerateSourceUploadUrl` method.

Generated from protobuf message `google.cloud.functions.v2.GenerateUploadUrlResponse`

## Namespace

Google \\ Cloud \\ Functions \\ V2

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ upload_url` | `string` The generated Google Cloud Storage signed URL that should be used for a function source code upload. The uploaded file should be a zip archive which contains a function. |
| `↳ storage_source` | `https://docs.cloud.google.com/php/docs/reference/cloud-functions/latest/V2.StorageSource` The location of the source code in the upload bucket. Once the archive is uploaded using the `upload_url` use this field to set the `function.build_config.source.storage_source` during CreateFunction and UpdateFunction. Generation defaults to 0, as Cloud Storage provides a new generation only upon uploading a new object or version of an object. |

### getUploadUrl

The generated Google Cloud Storage signed URL that should be used for a
function source code upload. The uploaded file should be a zip archive
which contains a function.

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

### setUploadUrl

The generated Google Cloud Storage signed URL that should be used for a
function source code upload. The uploaded file should be a zip archive
which contains a function.

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

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

### getStorageSource

The location of the source code in the upload bucket.

Once the archive is uploaded using the `upload_url` use this field to
set the `function.build_config.source.storage_source`
during CreateFunction and UpdateFunction.
Generation defaults to 0, as Cloud Storage provides a new generation only
upon uploading a new object or version of an object.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-functions/latest/V2.StorageSource|null` |   |

### hasStorageSource

### clearStorageSource

### setStorageSource

The location of the source code in the upload bucket.

Once the archive is uploaded using the `upload_url` use this field to
set the `function.build_config.source.storage_source`
during CreateFunction and UpdateFunction.
Generation defaults to 0, as Cloud Storage provides a new generation only
upon uploading a new object or version of an object.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-functions/latest/V2.StorageSource` |

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