---
title: "publishablePublishToCurrentChannel"
description: >
  Publish a resource to the current channel. When the resource is a product, it becomes visible in the channel only when marked as active. Products sold exclusively by subscription (requiresSellingPlan: true) can only be published to the online store.
doc_type: graphql
doc_category: adminGraphQL
doc_version: v20270301
source_url:
  html: 'https://developer.shopline.com/docs/admin-graph-ql-api/store-properties/mutations/publishable-publish-to-current-channel'
  md: 'https://developer.shopline.com/docs/admin-graph-ql-api/store-properties/mutations/publishable-publish-to-current-channel.md'
---
# publishablePublishToCurrentChannel

Publish a resource to the current channel. When the resource is a product, it becomes visible in the channel only when marked as active. Products sold exclusively by subscription (requiresSellingPlan: true) can only be published to the online store.

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

## Type Signature

`PublishablePublishToCurrentChannelPayload`

## Required Permissions

* `write_publications`

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

* `id`

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

  The resource for which to create or update a publication.

## Returns

* `shop`

  [Shop!](https://developer.shopline.com/docs/admin-graph-ql-api/store-properties/objects/shop.md)

  The object representing the user's store.

* `userErrors`

  [[UserError!]!](https://developer.shopline.com/docs/admin-graph-ql-api/common-objects/objects/user-error.md)

  A list of errors that occurred during execution.

## Code Example

```graphql
mutation publishablePublishToCurrentChannel($id: ID! ) {
	publishablePublishToCurrentChannel(id: $id ) 
		 {
			# PublishablePublishToCurrentChannelPayload fields
		}
		
	}

```

## Variables

```json
{
  "id": {}
}
```

## Examples

### Publish resources to the current channel


Publish resources to the current channel. A product is visible within the channel only if its status is active. Products exclusively available through subscription (requestSellingPlan: true) are publishable only in online stores.

**Request:**

```json
mutation PublishablePublishToCurrentChannel {
    publishablePublishToCurrentChannel(
        id: "gid://shopline/Product/16055271775622479314742093"
    ) {
        userErrors {
            field
            message
        }
    }
}
```

**Response:**

```json
{
  "data": {
    "data": {
      "publishablePublishToCurrentChannel": {
        "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).

