> Portal Navigation: > > - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version. > - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages). > - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`). > - Top-level index of all portals: https://dev.wix.com/docs/llms.txt > - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt # SubmitGeneratedMockups # Package: suppliersHub # Namespace: MarketplaceProviderSubmissions # Method link: https://dev.wix.com/docs/api-reference/business-solutions/suppliers-hub/marketplace-provider-submissions/submit-generated-mockups.md ## Permission Scopes: Write Marketplace: SCOPE.SUPPLIERS_HUB.WRITE_MARKETPLACE ## Introduction Submits generated mockup images for one or more products. Marketplace providers call this method to report completion of asynchronous mockup generation initiated via [Bulk Generate Mockups](https://dev.wix.com/docs/api-reference/business-solutions/suppliers-hub/marketplace-provider-service-plugin/bulk-generate-mockups.md). Include the generated mockup URL when `status` is `COMPLETED`, or set `status` to `FAILED` for products where generation couldn't be completed. Each mockup is keyed by the combination of provider, `providerProductId`, and `imageType`, so a product can have a separate mockup submitted for each supported image type (for example, `SITE_LOGO` and `CUSTOM`). Providers can batch results across multiple calls in any grouping—there's no requirement to submit all products from a given [Bulk Generate Mockups](https://dev.wix.com/docs/api-reference/business-solutions/suppliers-hub/marketplace-provider-service-plugin/bulk-generate-mockups.md) request in a single submission. --- ## REST API ### Schema ``` Method: submitGeneratedMockups Description: Submits generated mockup images for one or more products. Marketplace providers call this method to report completion of asynchronous mockup generation initiated via [Bulk Generate Mockups](https://dev.wix.com/docs/api-reference/business-solutions/suppliers-hub/marketplace-provider-service-plugin/bulk-generate-mockups.md). Include the generated mockup URL when `status` is `COMPLETED`, or set `status` to `FAILED` for products where generation couldn't be completed. Each mockup is keyed by the combination of provider, `providerProductId`, and `imageType`, so a product can have a separate mockup submitted for each supported image type (for example, `SITE_LOGO` and `CUSTOM`). Providers can batch results across multiple calls in any grouping—there's no requirement to submit all products from a given [Bulk Generate Mockups](https://dev.wix.com/docs/api-reference/business-solutions/suppliers-hub/marketplace-provider-service-plugin/bulk-generate-mockups.md) request in a single submission. URL: https://www.wixapis.com/suppliershub/v2/submit-generated-mockups Method: POST # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present. Required parameters: mockups.providerProductId, mockups.imageType, mockups.status Method parameters: param name: mockups | type: array | description: Mockup generation results. Include the generated mockup URL for successful generations, or set `status` to `FAILED` for unsuccessful ones. | validation: minItems 1, maxItems 100 - name: providerProductId | type: string | description: Product GUID on the provider's platform. | required: true | validation: minLength 1, maxLength 36 - name: mockupUrl | type: string | description: URL of the generated mockup image. Required when `status` is `COMPLETED`. | validation: format WEB_URL - name: imageType | type: ImageType | description: Type of image that was applied to generate the mockup. Must match the `imageType` from the original [Bulk Generate Mockups](https://dev.wix.com/docs/api-reference/business-solutions/suppliers-hub/marketplace-provider-service-plugin/bulk-generate-mockups.md) request for this product. Mockups are stored per product and image type, so a product can hold a separate mockup for each supported type, such as `SITE_LOGO` and `CUSTOM`. | required: true - enum: - SITE_LOGO: Site logo automatically fetched from the Wix site's configured logo. - CUSTOM: Custom image provided by the site owner. - FALLBACK: Placeholder image used when the site has no logo and no custom image is provided. Displays "Your image here" text. - name: status | type: MockupStatus | description: Mockup generation status. Providers typically submit `COMPLETED` or `FAILED` to report the final outcome. `PENDING` may be submitted to indicate that generation is still in progress, but doesn't currently drive any state change on the Wix side. | required: true - enum: - PENDING: Mockup generation is in progress. - COMPLETED: Mockup generation completed successfully. - FAILED: Mockup generation failed. Return type: SubmitGeneratedMockupsResponse - name: results | type: array | description: Per-item results for each mockup in the request, in the same order. | validation: minItems 1, maxItems 100 - name: itemMetadata | type: ItemMetadata | description: Metadata for this item's submission, including success or failure information. - name: id | type: string | description: Item GUID. Should always be available, unless it's impossible (for example, when failing to create an item). | validation: minLength 1, maxLength 36 - name: originalIndex | type: integer | description: Index of the item within the request array. Allows for correlation between request and response items. - name: success | type: boolean | description: Whether the requested action was successful for this item. When `false`, the `error` field is populated. - name: error | type: ApplicationError | description: Details about the error in case of failure. - name: code | type: string | description: Error code. - name: description | type: string | description: Description of the error. - name: data | type: object | description: Data related to the error. - name: bulkActionMetadata | type: BulkActionMetadata | description: Bulk operation metadata. - name: totalSuccesses | type: integer | description: Number of items that were successfully processed. - name: totalFailures | type: integer | description: Number of items that couldn't be processed. - name: undetailedFailures | type: integer | description: Number of failures without details because detailed failure threshold was exceeded. ``` ### Examples ### Submit generated mockup results Reports the outcome of asynchronous mockup generation for one or more products ```curl curl -X POST \ 'https://www.wixapis.com/suppliers-hub/marketplace-provider-host/v2/submit-generated-mockups' \ -H 'Authorization: ' \ -H 'Content-Type: application/json' \ -d '{ "mockups": [ { "providerProductId": "001", "imageType": "CUSTOM", "status": "COMPLETED", "mockupUrl": "https://static.wixstatic.com/media/f53f1bfcae4648c681d1964f3a90b386.jpg" }, { "providerProductId": "003", "imageType": "CUSTOM", "status": "FAILED" } ] }' ``` ---