---
title: "companyRevokeMainContact"
description: "Void the company's primary contact"
doc_type: graphql
doc_category: adminGraphQL
doc_version: v20270301
source_url:
  html: 'https://developer.shopline.com/docs/admin-graph-ql-api/b-2-b/mutations/company-revoke-main-contact'
  md: 'https://developer.shopline.com/docs/admin-graph-ql-api/b-2-b/mutations/company-revoke-main-contact.md'
---
# companyRevokeMainContact

Void the company's primary contact

- **Required Scopes:** `write_customers`
- **API Version:** v20270301
- **API Type:** Admin
- **API Protocol:** GraphQL
- **Operation Type:** Mutation

## Type Signature

`CompanyRevokeMainContactPayload`

## Required Permissions

* `write_customers`

An access token is required to call this API. Refer to [Authorization](https://developer.shopline.com/docs/apps/api-instructions-for-use/graph-ql-admin-api/overview.md) for more information about how to obtain the token.

## Arguments

* `companyId`

  [ID!](https://developer.shopline.com/docs/admin-graph-ql-api/common/scalars/id.md)

  Company id

## Returns

* `company`

  [Company](https://developer.shopline.com/docs/admin-graph-ql-api/b-2-b/objects/company.md)

  Company information

* `userErrors`

  [[BusinessCustomerUserError!]!](https://developer.shopline.com/docs/admin-graph-ql-api/customers/objects/business-customer-user-error.md)

  Error message

## Code Example

```graphql
mutation companyRevokeMainContact($companyId: ID! ) {
	companyRevokeMainContact(companyId: $companyId ) 
		 {
			# CompanyRevokeMainContactPayload fields
		}
		
	}

```

## Variables

```json
{
  "companyId": {}
}
```

## Examples

### Revoke the company's main contact

Revoke the company's main contact

**Request:**

```json
{
  "companyId": "gid://shopline/Company/6254924101557166237"
}

```

**Response:**

```json
{
  "data": {
    "data": {
      "companyRevokeMainContact": {
        "company": {
          "id": "gid://shopline/Company/6254924101557166237",
          "mainContact": null,
          "name": "test2"
        },
        "userErrors": []
      }
    }
  }
}
```

## Error Handling

For detailed information about common codes, see [Status and error codes](https://developer.shopline.com/docs/apps/api-instructions-for-use/graph-ql-admin-api/overview.md#status-and-error-codes).

