Skip to main content

Product Page Extensions API

The Shop Minis Extensions API is a GraphQL API that powers Minis Extensions. This page shows the schema that is available to Extensions targeting the Product Page.

Product Page Extensions targets

The Extensions targets determines where an extension will be rendered within the Shop app. However, Shop is responsible for determining the specific placement of extensions on its screens. The Product schema can be used to render the Extension on the following Product Page targets:

TargetDescription
shop.product.block.renderA product details page within the Shop app.
shop.product.variants.render-beforeThe extension will render on the product details page before the variants within the Shop app.
shop.product.variants.render-afterThe extension will render on the product details page after the variants within the Shop app.
Table of Contents

Query

The schema’s entry-point for queries. This acts as the public, top-level API from which all queries must start.

FieldArgumentTypeDescription
productProduct

The current product.

shopShop

The current shop.

Objects

Collection

A collection represents a grouping of products that a shop owner can create to organize them or make their shops easier to browse.

FieldArgumentTypeDescription
idID!

A globally-unique ID.

productsProductConnection!

List of products in the collection.

afterString

Returns the elements in the list that come after the specified cursor.

beforeString

Returns the elements in the list that come before the specified cursor.

firstInt

Returns the first n elements from the list.

lastInt

Returns the last n elements from the list.

reverseBoolean

Reverse the order of the underlying list.

sortKeyProductCollectionSortKeys

Sort the underlying list by the given key.

titleString!

The collection’s name. Limit of 255 characters.

CollectionConnection

An auto-generated type for paginating through multiple Collections.

FieldArgumentTypeDescription
edges[CollectionEdge!]!

A list of edges.

nodes[Collection!]!

A list of the nodes contained in CollectionEdge.

pageInfoPageInfo!

Information to aid in pagination.

CollectionEdge

An auto-generated type which holds one Collection and a cursor during pagination.

FieldArgumentTypeDescription
cursorString!

A cursor for use in pagination.

nodeCollection!

The item at the end of CollectionEdge.

Domain

Represents an web address.

FieldArgumentTypeDescription
hostString!

The host name of the domain (eg: example.com).

sslEnabledBoolean!

Whether SSL is enabled or not.

urlURL!

The URL of the domain (eg: https://example.com).

Image

Represents an image resource.

FieldArgumentTypeDescription
idID

A unique ID for the image.

urlURL!

The location of the image as a URL.

If no transform options are specified, then the original image will be preserved including any pre-applied transforms.

All transformation options are considered "best-effort". Any transformation that the original image type doesn't support will be ignored.

If you need multiple variations of the same image, then you can use GraphQL aliases.

transformImageTransformInput

A set of options to transform the original image.

MediaImage

Represents a Shopify hosted image.

FieldArgumentTypeDescription
idID!

A globally-unique ID.

imageImage

The image for the media.

Metafield

Metafields represent custom metadata attached to a resource. Metafields can be sorted into namespaces and are comprised of keys, values, and value types.

FieldArgumentTypeDescription
idID!

A globally-unique ID.

referenceMetafieldReference

Returns a reference object if the metafield's type is a resource reference.

referencesMetafieldReferenceConnection

A list of reference objects if the metafield's type is a resource reference list.

afterString

Returns the elements in the list that come after the specified cursor.

beforeString

Returns the elements in the list that come before the specified cursor.

firstInt

Returns the first n elements from the list.

lastInt

Returns the last n elements from the list.

typeString!

The type name of the metafield. Refer to the list of supported types.

valueString!

The data stored in the metafield. Always stored as a string, regardless of the metafield's type.

MetafieldReferenceConnection

An auto-generated type for paginating through multiple MetafieldReferences.

FieldArgumentTypeDescription
edges[MetafieldReferenceEdge!]!

A list of edges.

nodes[MetafieldReference!]!

A list of the nodes contained in MetafieldReferenceEdge.

pageInfoPageInfo!

Information to aid in pagination.

MetafieldReferenceEdge

An auto-generated type which holds one MetafieldReference and a cursor during pagination.

FieldArgumentTypeDescription
cursorString!

A cursor for use in pagination.

nodeMetafieldReference!

The item at the end of MetafieldReferenceEdge.

Metaobject

An instance of a user-defined model based on a MetaobjectDefinition.

FieldArgumentTypeDescription
fieldMetaobjectField

Accesses a field of the object by key.

keyString!

The key of the field.

idID!

A globally-unique ID.

MetaobjectField

Provides the value of a Metaobject field.

FieldArgumentTypeDescription
referenceMetafieldReference

A referenced object if the field type is a resource reference.

referencesMetafieldReferenceConnection

A list of referenced objects if the field type is a resource reference list.

afterString

Returns the elements in the list that come after the specified cursor.

beforeString

Returns the elements in the list that come before the specified cursor.

firstInt

Returns the first n elements from the list.

lastInt

Returns the last n elements from the list.

valueString

The field value.

MoneyV2

A monetary value with currency.

FieldArgumentTypeDescription
amountDecimal!

Decimal money amount.

currencyCodeCurrencyCode!

Currency of the money.

PageInfo

Returns information about pagination in a connection, in accordance with the Relay specification. For more information, please read our GraphQL Pagination Usage Guide.

FieldArgumentTypeDescription
endCursorString

The cursor corresponding to the last node in edges.

hasNextPageBoolean!

Whether there are more pages to fetch following the current page.

hasPreviousPageBoolean!

Whether there are any pages prior to the current page.

startCursorString

The cursor corresponding to the first node in edges.

Product

A product represents an individual item for sale in a Shopify store. Products are often physical, but they don't have to be. For example, a digital download (such as a movie, music or ebook file) also qualifies as a product, as do services (such as equipment rental, work for hire, customization of another product or an extended warranty).

FieldArgumentTypeDescription
availableForSaleBoolean!

Indicates if at least one product variant is available for sale.

collectionsCollectionConnection!

List of collections a product belongs to.

afterString

Returns the elements in the list that come after the specified cursor.

beforeString

Returns the elements in the list that come before the specified cursor.

firstInt

Returns the first n elements from the list.

lastInt

Returns the last n elements from the list.

reverseBoolean

Reverse the order of the underlying list.

featuredImageImage

The featured image for the product.

This field is functionally equivalent to images(first: 1).

idID!

A globally-unique ID.

metafieldMetafield

Returns a metafield found by namespace and key.

keyString!

The identifier for the metafield.

namespaceString

The container the metafield belongs to. If omitted, the app-reserved namespace will be used.

metafields[Metafield]!

The metafields associated with the resource matching the supplied list of namespaces and keys.

identifiers[HasMetafieldsIdentifier!]!

The list of metafields to retrieve by namespace and key.

The input must not contain more than 250 values.

options[ProductOption!]!

List of product options.

firstInt

Truncate the array result to this size.

priceRangeProductPriceRange!

The price range.

reviewsAverageRatingFloat

The average rating of the product.

reviewsCountInt

The number of reviews for the product.

titleString!

The product’s title.

variantsProductVariantConnection!

List of the product’s variants.

afterString

Returns the elements in the list that come after the specified cursor.

beforeString

Returns the elements in the list that come before the specified cursor.

firstInt

Returns the first n elements from the list.

lastInt

Returns the last n elements from the list.

reverseBoolean

Reverse the order of the underlying list.

sortKeyProductVariantSortKeys

Sort the underlying list by the given key.

ProductConnection

An auto-generated type for paginating through multiple Products.

FieldArgumentTypeDescription
edges[ProductEdge!]!

A list of edges.

nodes[Product]!

A list of the nodes contained in ProductEdge.

pageInfoPageInfo!

Information to aid in pagination.

ProductEdge

An auto-generated type which holds one Product and a cursor during pagination.

FieldArgumentTypeDescription
cursorString!

A cursor for use in pagination.

nodeProduct

The item at the end of ProductEdge.

ProductOption

Product property names like "Size", "Color", and "Material" that the customers can select. Variants are selected based on permutations of these options. 255 characters limit each.

FieldArgumentTypeDescription
idID!

A globally-unique ID.

nameString!

The product option’s name.

values[String!]!

The corresponding value to the product option name.

ProductPriceRange

The price range of the product.

FieldArgumentTypeDescription
maxVariantPriceMoneyV2!

The highest variant's price.

minVariantPriceMoneyV2!

The lowest variant's price.

ProductVariant

A product variant represents a different version of a product, such as differing sizes or differing colors.

FieldArgumentTypeDescription
availableForSaleBoolean!

Indicates if the product variant is available for sale.

compareAtPriceMoneyV2

The compare at price of the variant. This can be used to mark a variant as on sale, when compareAtPrice is higher than price.

currentlyNotInStockBoolean!

Whether a product is out of stock but still available for purchase (used for backorders).

idID!

A globally-unique ID.

imageImage

Image associated with the product variant. This field falls back to the product image if no image is available.

isFavoritedBoolean!

Whether the product variant is favorited by the current user.

metafieldMetafield

Returns a metafield found by namespace and key.

keyString!

The identifier for the metafield.

namespaceString

The container the metafield belongs to. If omitted, the app-reserved namespace will be used.

priceMoneyV2!

The product variant’s price.

productProduct!

The product object that the product variant belongs to.

selectedOptions[SelectedOption!]!

List of product options applied to the variant.

titleString!

The product variant’s title.

ProductVariantConnection

An auto-generated type for paginating through multiple ProductVariants.

FieldArgumentTypeDescription
edges[ProductVariantEdge!]!

A list of edges.

nodes[ProductVariant!]!

A list of the nodes contained in ProductVariantEdge.

pageInfoPageInfo!

Information to aid in pagination.

ProductVariantEdge

An auto-generated type which holds one ProductVariant and a cursor during pagination.

FieldArgumentTypeDescription
cursorString!

A cursor for use in pagination.

nodeProductVariant!

The item at the end of ProductVariantEdge.

SelectedOption

Properties used by customers to select a product variant. Products can have multiple options, like different sizes or colors.

FieldArgumentTypeDescription
nameString!

The product option’s name.

valueString!

The product option’s value.

Shop

Shop represents a collection of the general settings and information about the shop.

FieldArgumentTypeDescription
idID!

A globally-unique ID.

metafieldMetafield

Returns a metafield found by namespace and key.

keyString!

The identifier for the metafield.

namespaceString

The container the metafield belongs to. If omitted, the app-reserved namespace will be used.

metafields[Metafield]!

The metafields associated with the resource matching the supplied list of namespaces and keys.

identifiers[HasMetafieldsIdentifier!]!

The list of metafields to retrieve by namespace and key.

The input must not contain more than 250 values.

myshopifyDomainDomain!

The shop’s permanent domain.

nameString!

The shop’s name.

Video

Represents a Shopify hosted video.

FieldArgumentTypeDescription
idID!

A globally-unique ID.

sources[VideoSource!]!

The sources for a video.

VideoSource

Represents a source for a Shopify hosted video.

FieldArgumentTypeDescription
urlString!

The URL of the video.

Inputs

CropRegionInput

The input fields for defining an arbitrary cropping region.

FieldTypeDescription
heightInt!

Height of the region of the image to extract when using the region crop mode.

leftInt!

Left position of the region of the image to extract when using the region crop mode.

topInt!

Top position of the region of the image to extract when using the region crop mode.

widthInt!

Width of the region of the image to extract when using the region crop mode.

HasMetafieldsIdentifier

The input fields to identify a metafield on an owner resource by namespace and key.

FieldTypeDescription
keyString!

The identifier for the metafield.

namespaceString

The container the metafield belongs to. If omitted, the app-reserved namespace will be used.

ImageTransformInput

The available options for transforming an image.

All transformation options are considered best effort. Any transformation that the original image type doesn't support will be ignored.

FieldTypeDescription
cropCropRegion

The region of the image to remain after cropping. Must be used in conjunction with the maxWidth and/or maxHeight fields, where the maxWidth and maxHeight aren't equal. The crop argument should coincide with the smaller value. A smaller maxWidth indicates a LEFT or RIGHT crop, while a smaller maxHeight indicates a TOP or BOTTOM crop. For example, { maxWidth: 5, maxHeight: 10, crop: LEFT } will result in an image with a width of 5 and height of 10, where the right side of the image is removed.

cropRegionCropRegionInput

Defines an arbitrary cropping region.

maxHeightInt

Image height in pixels between 1 and 5760.

maxWidthInt

Image width in pixels between 1 and 5760.

preferredContentTypeImageContentType

Convert the source image into the preferred content type. Supported conversions: .svg to .png, any file type to .jpg, and any file type to .webp.

scaleInt

Image size multiplier for high-resolution retina displays. Must be within 1..3.

Enums

CropRegion

The part of the image that should remain after cropping.

ValueDescription
BOTTOM

Keep the bottom of the image.

CENTER

Keep the center of the image.

LEFT

Keep the left of the image.

REGION

Crop the exact region of the image specified by the crop_left, crop_top, crop_width and crop_height parameters.

RIGHT

Keep the right of the image.

TOP

Keep the top of the image.

CurrencyCode

The three-letter currency codes that represent the world currencies used in stores. These include standard ISO 4217 codes, legacy codes, and non-standard codes.

ValueDescription
AED

United Arab Emirates Dirham (AED).

AFN

Afghan Afghani (AFN).

ALL

Albanian Lek (ALL).

AMD

Armenian Dram (AMD).

ANG

Netherlands Antillean Guilder.

AOA

Angolan Kwanza (AOA).

ARS

Argentine Pesos (ARS).

AUD

Australian Dollars (AUD).

AWG

Aruban Florin (AWG).

AZN

Azerbaijani Manat (AZN).

BAM

Bosnia and Herzegovina Convertible Mark (BAM).

BBD

Barbadian Dollar (BBD).

BDT

Bangladesh Taka (BDT).

BGN

Bulgarian Lev (BGN).

BHD

Bahraini Dinar (BHD).

BIF

Burundian Franc (BIF).

BMD

Bermudian Dollar (BMD).

BND

Brunei Dollar (BND).

BOB

Bolivian Boliviano (BOB).

BRL

Brazilian Real (BRL).

BSD

Bahamian Dollar (BSD).

BTN

Bhutanese Ngultrum (BTN).

BWP

Botswana Pula (BWP).

BYN

Belarusian Ruble (BYN).

BYR

Belarusian Ruble (BYR).

BZD

Belize Dollar (BZD).

CAD

Canadian Dollars (CAD).

CDF

Congolese franc (CDF).

CHF

Swiss Francs (CHF).

CLP

Chilean Peso (CLP).

CNY

Chinese Yuan Renminbi (CNY).

COP

Colombian Peso (COP).

CRC

Costa Rican Colones (CRC).

CVE

Cape Verdean escudo (CVE).

CZK

Czech Koruny (CZK).

DJF

Djiboutian Franc (DJF).

DKK

Danish Kroner (DKK).

DOP

Dominican Peso (DOP).

DZD

Algerian Dinar (DZD).

EGP

Egyptian Pound (EGP).

ERN

Eritrean Nakfa (ERN).

ETB

Ethiopian Birr (ETB).

EUR

Euro (EUR).

FJD

Fijian Dollars (FJD).

FKP

Falkland Islands Pounds (FKP).

GBP

United Kingdom Pounds (GBP).

GEL

Georgian Lari (GEL).

GHS

Ghanaian Cedi (GHS).

GIP

Gibraltar Pounds (GIP).

GMD

Gambian Dalasi (GMD).

GNF

Guinean Franc (GNF).

GTQ

Guatemalan Quetzal (GTQ).

GYD

Guyanese Dollar (GYD).

HKD

Hong Kong Dollars (HKD).

HNL

Honduran Lempira (HNL).

HRK

Croatian Kuna (HRK).

HTG

Haitian Gourde (HTG).

HUF

Hungarian Forint (HUF).

IDR

Indonesian Rupiah (IDR).

ILS

Israeli New Shekel (NIS).

INR

Indian Rupees (INR).

IQD

Iraqi Dinar (IQD).

IRR

Iranian Rial (IRR).

ISK

Icelandic Kronur (ISK).

JEP

Jersey Pound.

JMD

Jamaican Dollars (JMD).

JOD

Jordanian Dinar (JOD).

JPY

Japanese Yen (JPY).

KES

Kenyan Shilling (KES).

KGS

Kyrgyzstani Som (KGS).

KHR

Cambodian Riel.

KID

Kiribati Dollar (KID).

KMF

Comorian Franc (KMF).

KRW

South Korean Won (KRW).

KWD

Kuwaiti Dinar (KWD).

KYD

Cayman Dollars (KYD).

KZT

Kazakhstani Tenge (KZT).

LAK

Laotian Kip (LAK).

LBP

Lebanese Pounds (LBP).

LKR

Sri Lankan Rupees (LKR).

LRD

Liberian Dollar (LRD).

LSL

Lesotho Loti (LSL).

LTL

Lithuanian Litai (LTL).

LVL

Latvian Lati (LVL).

LYD

Libyan Dinar (LYD).

MAD

Moroccan Dirham.

MDL

Moldovan Leu (MDL).

MGA

Malagasy Ariary (MGA).

MKD

Macedonia Denar (MKD).

MMK

Burmese Kyat (MMK).

MNT

Mongolian Tugrik.

MOP

Macanese Pataca (MOP).

MRU

Mauritanian Ouguiya (MRU).

MUR

Mauritian Rupee (MUR).

MVR

Maldivian Rufiyaa (MVR).

MWK

Malawian Kwacha (MWK).

MXN

Mexican Pesos (MXN).

MYR

Malaysian Ringgits (MYR).

MZN

Mozambican Metical.

NAD

Namibian Dollar.

NGN

Nigerian Naira (NGN).

NIO

Nicaraguan Córdoba (NIO).

NOK

Norwegian Kroner (NOK).

NPR

Nepalese Rupee (NPR).

NZD

New Zealand Dollars (NZD).

OMR

Omani Rial (OMR).

PAB

Panamian Balboa (PAB).

PEN

Peruvian Nuevo Sol (PEN).

PGK

Papua New Guinean Kina (PGK).

PHP

Philippine Peso (PHP).

PKR

Pakistani Rupee (PKR).

PLN

Polish Zlotych (PLN).

PYG

Paraguayan Guarani (PYG).

QAR

Qatari Rial (QAR).

RON

Romanian Lei (RON).

RSD

Serbian dinar (RSD).

RUB

Russian Rubles (RUB).

RWF

Rwandan Franc (RWF).

SAR

Saudi Riyal (SAR).

SBD

Solomon Islands Dollar (SBD).

SCR

Seychellois Rupee (SCR).

SDG

Sudanese Pound (SDG).

SEK

Swedish Kronor (SEK).

SGD

Singapore Dollars (SGD).

SHP

Saint Helena Pounds (SHP).

SLL

Sierra Leonean Leone (SLL).

SOS

Somali Shilling (SOS).

SRD

Surinamese Dollar (SRD).

SSP

South Sudanese Pound (SSP).

STD

Sao Tome And Principe Dobra (STD).

STN

Sao Tome And Principe Dobra (STN).

SYP

Syrian Pound (SYP).

SZL

Swazi Lilangeni (SZL).

THB

Thai baht (THB).

TJS

Tajikistani Somoni (TJS).

TMT

Turkmenistani Manat (TMT).

TND

Tunisian Dinar (TND).

TOP

Tongan Pa'anga (TOP).

TRY

Turkish Lira (TRY).

TTD

Trinidad and Tobago Dollars (TTD).

TWD

Taiwan Dollars (TWD).

TZS

Tanzanian Shilling (TZS).

UAH

Ukrainian Hryvnia (UAH).

UGX

Ugandan Shilling (UGX).

USD

United States Dollars (USD).

UYU

Uruguayan Pesos (UYU).

UZS

Uzbekistan som (UZS).

VED

Venezuelan Bolivares (VED).

VEF

Venezuelan Bolivares (VEF).

VES

Venezuelan Bolivares Soberanos (VES).

VND

Vietnamese đồng (VND).

VUV

Vanuatu Vatu (VUV).

WST

Samoan Tala (WST).

XAF

Central African CFA Franc (XAF).

XCD

East Caribbean Dollar (XCD).

XOF

West African CFA franc (XOF).

XPF

CFP Franc (XPF).

XXX

Unrecognized currency.

YER

Yemeni Rial (YER).

ZAR

South African Rand (ZAR).

ZMW

Zambian Kwacha (ZMW).

ImageContentType

List of supported image content types.

ValueDescription
BMP

A BMP image.

JPG

A JPG image.

PNG

A PNG image.

WEBP

A WEBP image.

ProductCollectionSortKeys

The set of valid sort keys for the ProductCollection query.

ValueDescription
BEST_SELLING

Sort by the best-selling value.

COLLECTION_DEFAULT

Sort by the collection-default value.

CREATED

Sort by the created value.

ID

Sort by the id value.

MANUAL

Sort by the manual value.

PRICE

Sort by the price value.

RELEVANCE

Sort by relevance to the search terms when the query parameter is specified on the connection. Don't use this sort key when no search query is specified.

TITLE

Sort by the title value.

ProductVariantSortKeys

The set of valid sort keys for the ProductVariant query.

ValueDescription
ID

Sort by the id value.

POSITION

Sort by the position value.

RELEVANCE

Sort by relevance to the search terms when the query parameter is specified on the connection. Don't use this sort key when no search query is specified.

SKU

Sort by the sku value.

TITLE

Sort by the title value.

Scalars

Boolean

The Boolean scalar type represents true or false.

Decimal

A signed decimal number, which supports arbitrary precision and is serialized as a string.

Example values: "29.99", "29.999".

Float

The Float scalar type represents signed double-precision fractional values as specified by IEEE 754.

ID

The ID scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as "4") or integer (such as 4) input value will be accepted as an ID.

Int

The Int scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.

String

The String scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.

URL

Represents an RFC 3986 and RFC 3987-compliant URI string.

For example, "https://johns-apparel.myshopify.com" is a valid URL. It includes a scheme (https) and a host (johns-apparel.myshopify.com).

Unions

MetafieldReference

Returns the resource which is being referred to by a metafield.

TypeDescription
Collection

A collection represents a grouping of products that a shop owner can create to organize them or make their shops easier to browse.

MediaImage

Represents a Shopify hosted image.

Metaobject

An instance of a user-defined model based on a MetaobjectDefinition.

Product

A product represents an individual item for sale in a Shopify store. Products are often physical, but they don't have to be. For example, a digital download (such as a movie, music or ebook file) also qualifies as a product, as do services (such as equipment rental, work for hire, customization of another product or an extended warranty).

ProductVariant

A product variant represents a different version of a product, such as differing sizes or differing colors.

Video

Represents a Shopify hosted video.