@lap v0.3
# Machine-readable API spec. Each @endpoint block is one API call.
@api Inventory API
@base https://api.ebay.com/sell/inventory/v1
@version 1.17.4
@auth OAuth2
@endpoints 33
@hint download_for_search
@toc bulk_create_or_replace_inventory_item(1), bulk_get_inventory_item(1), bulk_update_price_quantity(1), inventory_item(7), inventory_item_group(3), bulk_migrate_listing(1), bulk_create_offer(1), bulk_publish_offer(1), offer(10), location(7)

@group bulk_create_or_replace_inventory_item
@endpoint POST /bulk_create_or_replace_inventory_item
@required {Content-Type: str, Content-Language: str}
@optional {requests: [map{availability: map, condition: str, conditionDescription: str, conditionDescriptors: [map], locale: str, packageWeightAndSize: map, product: map, sku: str}]}
@returns(200) {responses: [map]}
@returns(207)
@errors {400, 500}

@endgroup

@group bulk_get_inventory_item
@endpoint POST /bulk_get_inventory_item
@required {Content-Type: str}
@optional {requests: [map{sku: str}]}
@returns(200) {responses: [map]}
@returns(207)
@errors {400, 500}

@endgroup

@group bulk_update_price_quantity
@endpoint POST /bulk_update_price_quantity
@required {Content-Type: str}
@optional {requests: [map{offers: [map], shipToLocationAvailability: map, sku: str}]}
@returns(200) {responses: [map]}
@returns(207)
@errors {400, 500}

@endgroup

@group inventory_item
@endpoint GET /inventory_item/{sku}
@required {sku: str}
@returns(200) {availability: map{pickupAtLocationAvailability: [map], shipToLocationAvailability: map{allocationByFormat: map{auction: int(int32), fixedPrice: int(int32)}, availabilityDistributions: [map], quantity: int(int32)}}, condition: str, conditionDescription: str, conditionDescriptors: [map], groupIds: [str], inventoryItemGroupKeys: [str], locale: str, packageWeightAndSize: map{dimensions: map{height: num, length: num, unit: str, width: num}, packageType: str, shippingIrregular: bool, weight: map{unit: str, value: num}}, product: map{aspects: str, brand: str, description: str, ean: [str], epid: str, imageUrls: [str], isbn: [str], mpn: str, subtitle: str, title: str, upc: [str], videoIds: [str]}, sku: str}
@errors {400, 404, 500}

@endpoint PUT /inventory_item/{sku}
@required {Content-Language: str, sku: str, Content-Type: str}
@optional {availability: map{pickupAtLocationAvailability: [map], shipToLocationAvailability: map}, condition: str, conditionDescription: str, conditionDescriptors: [map{additionalInfo: str, name: str, values: [str]}], packageWeightAndSize: map{dimensions: map, packageType: str, shippingIrregular: bool, weight: map}, product: map{aspects: str, brand: str, description: str, ean: [str], epid: str, imageUrls: [str], isbn: [str], mpn: str, subtitle: str, title: str, upc: [str], videoIds: [str]}}
@returns(200) {warnings: [map]}
@returns(201) {warnings: [map]}
@returns(204)
@errors {400, 500}

@endpoint DELETE /inventory_item/{sku}
@required {sku: str}
@returns(204)
@errors {400, 404, 500}

@endpoint GET /inventory_item
@optional {limit: str, offset: str}
@returns(200) {href: str, inventoryItems: [map], limit: int(int32), next: str, prev: str, size: int(int32), total: int(int32)}
@errors {400, 404, 500}

@endpoint GET /inventory_item/{sku}/product_compatibility
@required {sku: str}
@returns(200) {compatibleProducts: [map], sku: str}
@errors {400, 404, 500}

@endpoint PUT /inventory_item/{sku}/product_compatibility
@required {Content-Language: str, sku: str, Content-Type: str}
@optional {compatibleProducts: [map{compatibilityProperties: [map], notes: str, productFamilyProperties: map, productIdentifier: map}], sku: str}
@returns(200) {warnings: [map]}
@returns(201) {warnings: [map]}
@returns(204)
@errors {400, 500}

@endpoint DELETE /inventory_item/{sku}/product_compatibility
@required {sku: str}
@returns(204)
@errors {400, 404, 500}

@endgroup

@group inventory_item_group
@endpoint GET /inventory_item_group/{inventoryItemGroupKey}
@required {inventoryItemGroupKey: str}
@returns(200) {aspects: str, description: str, imageUrls: [str], inventoryItemGroupKey: str, subtitle: str, title: str, variantSKUs: [str], variesBy: map{aspectsImageVariesBy: [str], specifications: [map]}, videoIds: [str]}
@errors {400, 404, 500}

@endpoint PUT /inventory_item_group/{inventoryItemGroupKey}
@required {Content-Language: str, inventoryItemGroupKey: str, Content-Type: str}
@optional {aspects: str, description: str, imageUrls: [str], inventoryItemGroupKey: str, subtitle: str, title: str, variantSKUs: [str], variesBy: map{aspectsImageVariesBy: [str], specifications: [map]}, videoIds: [str]}
@returns(200) {warnings: [map]}
@returns(201) {warnings: [map]}
@returns(204)
@errors {400, 500}

@endpoint DELETE /inventory_item_group/{inventoryItemGroupKey}
@required {inventoryItemGroupKey: str}
@returns(204)
@errors {400, 404, 500}

@endgroup

@group bulk_migrate_listing
@endpoint POST /bulk_migrate_listing
@required {Content-Type: str}
@optional {requests: [map{listingId: str}]}
@returns(200) {responses: [map]}
@returns(207)
@errors {400, 500}

@endgroup

@group bulk_create_offer
@endpoint POST /bulk_create_offer
@required {Content-Language: str, Content-Type: str}
@optional {requests: [map{availableQuantity: int(int32), categoryId: str, charity: map, extendedProducerResponsibility: map, format: str, hideBuyerDetails: bool, includeCatalogProductDetails: bool, listingDescription: str, listingDuration: str, listingPolicies: map, listingStartDate: str, lotSize: int(int32), marketplaceId: str, merchantLocationKey: str, pricingSummary: map, quantityLimitPerBuyer: int(int32), regulatory: map, secondaryCategoryId: str, sku: str, storeCategoryNames: [str], tax: map}]}
@returns(200) {responses: [map]}
@returns(207)
@errors {400, 500}

@endgroup

@group bulk_publish_offer
@endpoint POST /bulk_publish_offer
@required {Content-Type: str}
@optional {requests: [map{offerId: str}]}
@returns(200) {responses: [map]}
@returns(207)
@errors {400, 500}

@endgroup

@group offer
@endpoint GET /offer
@optional {format: str, limit: str, marketplace_id: str, offset: str, sku: str}
@returns(200) {href: str, limit: int(int32), next: str, offers: [map], prev: str, size: int(int32), total: int(int32)}
@errors {400, 404, 500}

@endpoint POST /offer
@required {Content-Language: str, Content-Type: str}
@optional {availableQuantity: int(int32), categoryId: str, charity: map{charityId: str, donationPercentage: str}, extendedProducerResponsibility: map{ecoParticipationFee: map, producerProductId: str, productDocumentationId: str, productPackageId: str, shipmentPackageId: str}, format: str, hideBuyerDetails: bool, includeCatalogProductDetails: bool, listingDescription: str, listingDuration: str, listingPolicies: map{bestOfferTerms: map, eBayPlusIfEligible: bool, fulfillmentPolicyId: str, paymentPolicyId: str, productCompliancePolicyIds: [str], regionalProductCompliancePolicies: map, regionalTakeBackPolicies: map, returnPolicyId: str, shippingCostOverrides: [map], takeBackPolicyId: str}, listingStartDate: str, lotSize: int(int32), marketplaceId: str, merchantLocationKey: str, pricingSummary: map{auctionReservePrice: map, auctionStartPrice: map, minimumAdvertisedPrice: map, originallySoldForRetailPriceOn: str, originalRetailPrice: map, price: map, pricingVisibility: str}, quantityLimitPerBuyer: int(int32), regulatory: map{economicOperator: map, energyEfficiencyLabel: map, hazmat: map, repairScore: num}, secondaryCategoryId: str, sku: str, storeCategoryNames: [str], tax: map{applyTax: bool, thirdPartyTaxCategory: str, vatPercentage: num}}
@returns(201) {offerId: str, warnings: [map]}
@errors {400, 500}

@endpoint GET /offer/{offerId}
@required {offerId: str}
@returns(200) {availableQuantity: int(int32), categoryId: str, charity: map{charityId: str, donationPercentage: str}, extendedProducerResponsibility: map{ecoParticipationFee: map{currency: str, value: str}, producerProductId: str, productDocumentationId: str, productPackageId: str, shipmentPackageId: str}, format: str, hideBuyerDetails: bool, includeCatalogProductDetails: bool, listing: map{listingId: str, listingOnHold: bool, listingStatus: str, soldQuantity: int(int32)}, listingDescription: str, listingDuration: str, listingPolicies: map{bestOfferTerms: map{autoAcceptPrice: map{currency: str, value: str}, autoDeclinePrice: map{currency: str, value: str}, bestOfferEnabled: bool}, eBayPlusIfEligible: bool, fulfillmentPolicyId: str, paymentPolicyId: str, productCompliancePolicyIds: [str], regionalProductCompliancePolicies: map{countryPolicies: [map]}, regionalTakeBackPolicies: map{countryPolicies: [map]}, returnPolicyId: str, shippingCostOverrides: [map], takeBackPolicyId: str}, listingStartDate: str, lotSize: int(int32), marketplaceId: str, merchantLocationKey: str, offerId: str, pricingSummary: map{auctionReservePrice: map{currency: str, value: str}, auctionStartPrice: map{currency: str, value: str}, minimumAdvertisedPrice: map{currency: str, value: str}, originallySoldForRetailPriceOn: str, originalRetailPrice: map{currency: str, value: str}, price: map{currency: str, value: str}, pricingVisibility: str}, quantityLimitPerBuyer: int(int32), regulatory: map{economicOperator: map{addressLine1: str, addressLine2: str, city: str, companyName: str, country: str, email: str, phone: str, postalCode: str, stateOrProvince: str}, energyEfficiencyLabel: map{imageDescription: str, imageURL: str, productInformationSheet: str}, hazmat: map{component: str, pictograms: [str], signalWord: str, statements: [str]}, repairScore: num}, secondaryCategoryId: str, sku: str, status: str, storeCategoryNames: [str], tax: map{applyTax: bool, thirdPartyTaxCategory: str, vatPercentage: num}}
@errors {400, 404, 500}

@endpoint PUT /offer/{offerId}
@required {Content-Language: str, offerId: str, Content-Type: str}
@optional {availableQuantity: int(int32), categoryId: str, charity: map{charityId: str, donationPercentage: str}, extendedProducerResponsibility: map{ecoParticipationFee: map, producerProductId: str, productDocumentationId: str, productPackageId: str, shipmentPackageId: str}, hideBuyerDetails: bool, includeCatalogProductDetails: bool, listingDescription: str, listingDuration: str, listingPolicies: map{bestOfferTerms: map, eBayPlusIfEligible: bool, fulfillmentPolicyId: str, paymentPolicyId: str, productCompliancePolicyIds: [str], regionalProductCompliancePolicies: map, regionalTakeBackPolicies: map, returnPolicyId: str, shippingCostOverrides: [map], takeBackPolicyId: str}, listingStartDate: str, lotSize: int(int32), merchantLocationKey: str, pricingSummary: map{auctionReservePrice: map, auctionStartPrice: map, minimumAdvertisedPrice: map, originallySoldForRetailPriceOn: str, originalRetailPrice: map, price: map, pricingVisibility: str}, quantityLimitPerBuyer: int(int32), regulatory: map{economicOperator: map, energyEfficiencyLabel: map, hazmat: map, repairScore: num}, secondaryCategoryId: str, storeCategoryNames: [str], tax: map{applyTax: bool, thirdPartyTaxCategory: str, vatPercentage: num}}
@returns(200) {offerId: str, warnings: [map]}
@returns(204)
@errors {400, 404, 500}

@endpoint DELETE /offer/{offerId}
@required {offerId: str}
@returns(204)
@errors {400, 404, 500}

@endpoint POST /offer/get_listing_fees
@required {Content-Type: str}
@optional {offers: [map{offerId: str}]}
@returns(200) {feeSummaries: [map]}
@errors {400, 404, 500}

@endpoint POST /offer/{offerId}/publish/
@required {offerId: str}
@returns(200) {listingId: str, warnings: [map]}
@errors {400, 404, 500}

@endpoint POST /offer/publish_by_inventory_item_group/
@required {Content-Type: str}
@optional {inventoryItemGroupKey: str, marketplaceId: str}
@returns(200) {listingId: str, warnings: [map]}
@errors {400, 500}

@endpoint POST /offer/{offerId}/withdraw
@required {offerId: str}
@returns(200) {listingId: str, warnings: [map]}
@errors {400, 404, 500}

@endpoint POST /offer/withdraw_by_inventory_item_group
@required {Content-Type: str}
@optional {inventoryItemGroupKey: str, marketplaceId: str}
@returns(204)
@errors {400, 500}

@endgroup

@group location
@endpoint GET /location/{merchantLocationKey}
@required {merchantLocationKey: str}
@returns(200) {location: map{address: map{addressLine1: str, addressLine2: str, city: str, country: str, county: str, postalCode: str, stateOrProvince: str}, geoCoordinates: map{latitude: num, longitude: num}, locationId: str}, locationAdditionalInformation: str, locationInstructions: str, locationTypes: [str], locationWebUrl: str, merchantLocationKey: str, merchantLocationStatus: str, name: str, operatingHours: [map], phone: str, specialHours: [map]}
@errors {400, 404, 500}

@endpoint POST /location/{merchantLocationKey}
@required {merchantLocationKey: str, Content-Type: str}
@optional {location: map{address: map, geoCoordinates: map}, locationAdditionalInformation: str, locationInstructions: str, locationTypes: [str], locationWebUrl: str, merchantLocationStatus: str, name: str, operatingHours: [map{dayOfWeekEnum: str, intervals: [map]}], phone: str, specialHours: [map{date: str, intervals: [map]}]}
@returns(204)
@errors {400, 409, 500}

@endpoint DELETE /location/{merchantLocationKey}
@required {merchantLocationKey: str}
@returns(204)
@errors {400, 404, 500}

@endpoint POST /location/{merchantLocationKey}/disable
@required {merchantLocationKey: str}
@returns(200)
@errors {400, 404, 500}

@endpoint POST /location/{merchantLocationKey}/enable
@required {merchantLocationKey: str}
@returns(200)
@errors {400, 404, 500}

@endpoint GET /location
@optional {limit: str, offset: str}
@returns(200) {href: str, limit: int(int32), next: str, offset: int(int32), prev: str, total: int(int32), locations: [map]}
@errors {400, 500}

@endpoint POST /location/{merchantLocationKey}/update_location_details
@required {merchantLocationKey: str, Content-Type: str}
@optional {locationAdditionalInformation: str, locationInstructions: str, locationWebUrl: str, name: str, operatingHours: [map{dayOfWeekEnum: str, intervals: [map]}], phone: str, specialHours: [map{date: str, intervals: [map]}]}
@returns(204)
@errors {400, 404, 500}

@endgroup

@end
