syntax = "proto3";

package wix.fedinfra.exportservice.v1;
option java_package = "com.wixpress.fedinfra.exportservice.v1";
import "wix/common/paging.proto";

import "wix/catalog/api/v1/product.proto";
import "wix/catalog/api/v1/variant.proto";

message QueryVariantsExportSpiResponse {
  repeated ProductOrVariant items = 1;
  .wix.common.PagingMetadataV2 paging_metadata = 2;
}

message ProductOrVariant {
  string kind = 1;
  .wix.catalog.api.v1.Product product = 2;
  .wix.catalog.api.v1.StoreVariant variant = 3;
}

message QueryProductsExportSpiResponse {
  repeated ProductOrVariantV2 items = 1;
  .wix.common.PagingMetadataV2 paging_metadata = 2;
}

message ProductOrVariantV2 {
  string kind = 1;
  .wix.catalog.api.v1.Product product = 2;
  .wix.catalog.api.v1.Variant variant = 3;
}