Admin API / Types
UpdateCollectionInput
InputChanges to one collection. An omitted field keeps its value. Null is valid only for thumbnailId. An input without a change, or null in another field, fails with VALIDATION_ERROR.
input UpdateCollectionInputInput fields
| Field | Type | Description |
|---|---|---|
collectionId | ID! | The collection to change. |
defaultSort | CollectionItemSortInput | The default listing order. Listing collections only. |
displayName | NonEmptyString | Trimmed. Unique per item type, ignoring letter case; for a manual listing collection, its slug form must also differ from every tag slug of the marketplace. The slug does not change. |
featured | Boolean | True: the storefront home page shows a feed of the items. |
listingsFilter | Boolean | True: the storefront listings page offers the collection as a filter. Listing collections only. |
pinned | Boolean | True: the storefront home page shows the collection at the top. Listing collections only. |
rules | CollectionRulesInput | Replaces every rule. Automated listing collections only. Not with sellerPolicy: VALIDATION_ERROR. A legacy tag rule, which Collection.rules.sourceCollections reads as the collections that hold its tags, is removed too: to keep its listings, send the IDs of those collections in sourceCollectionIds. A hidden holder adds none while it is hidden, and a deleted holder gives CollectionRulesInvalidError. The listings of a tag whose collection is deleted, or that no collection holds, are lost. |
sellerPolicy | CollectionSellerPolicy | Who can add items and remove them. Manual collections only. |
thumbnailFileUrl | URL | The public URL of a PUBLIC District files image: File.url with access: PUBLIC in District API. Any last path segment is accepted. The collection stores its own copy of the 4096-pixel rendition on the marketplace image host, so a later change to the file in District files does not change the thumbnail. Not with thumbnailId: VALIDATION_ERROR. When District files does not answer the check or the copy fails, the mutation fails with error code MEDIA_FILE_CHECK_FAILED and writes nothing; send the same request again. |
thumbnailId | ID | Null removes the thumbnail. Otherwise an image that the caller owns, or the ID of the current thumbnail, which changes nothing. |
visibility | CollectionVisibility | Whether the storefront shows the collection. |