# Method: accounts.channelPartnerLinks.create

- [HTTP request](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks/create#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks/create#body.PATH_PARAMETERS)
- [Query parameters](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks/create#body.QUERY_PARAMETERS)
- [Request body](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks/create#body.request_body)
- [Response body](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks/create#body.response_body)
- [Authorization scopes](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks/create#body.aspect)
- [Try it!](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks/create#try-it)

Initiates a channel partner link between a distributor and a reseller, or between resellers in an n-tier reseller channel. Invited partners need to follow the inviteLinkUri provided in the response to accept. After accepting the invitation, a link is set up between the two parties. You must be a distributor to call this method.

Possible error codes:

- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- ALREADY_EXISTS: The ChannelPartnerLink sent in the request already exists.
- NOT_FOUND: No Cloud Identity customer exists for provided domain.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.

Return value: The new `https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks#ChannelPartnerLink` resource.

### HTTP request

`POST https://cloudchannel.googleapis.com/v1alpha1/{parent=accounts/*}/channelPartnerLinks`

The URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.

### Path parameters

| Parameters ||
|---|---|
| `parent` | `string` Required. Create a channel partner link for the provided reseller account's resource name. Parent uses the format: accounts/{account_id} |

### Query parameters

| Parameters ||
|---|---|
| `domain (deprecated)` | `string` Optional. The invited partner's domain. Either domain or channelPartnerLink.reseller_cloud_identity_id can be used to create a link. Deprecated: Use `https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks#ChannelPartnerLink.FIELDS.reseller_cloud_identity_id` instead |

### Request body

The request body contains an instance of `https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks#ChannelPartnerLink`.

### Response body

If successful, the response body contains a newly created instance of `https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.channelPartnerLinks#ChannelPartnerLink`.

### Authorization scopes

Requires the following OAuth scope:

- `https://www.googleapis.com/auth/apps.order`

For more information, see the [Authentication Overview](https://docs.cloud.google.com/docs/authentication#authorization-gcp).