This is an old revision of the document!
In order to get list of vendors perform API call to standard graphql endpoint.
Example:
{ vendorList { vendorId, vendorName, vendorAttn, email, telephone, fax, streetFull, street1, street2, city, zip, countryId, regionId, region, regionCode, billingUseShipping, billingTelephone, billingFax, billingStreetFull, billingStreet1, billingStreet2, billingCity, billingZip, billingCountryId, billingRegionId, billingRegion, billingRegionCode, status, carrierCode, urlKey, createdAt, vacationMode, vacationEnd, vacationMessage, accountType, isFeatured, ratingSummary } }
RESPONSE
{ "data": { "vendorList": [ { "vendorId": "1", "vendorName": "vendor1", "vendorAttn": "", "email": "wtsergo.test+v1@gmail.com", "telephone": "4025555555", "fax": null, "streetFull": "1234 Test", "street1": "1234 Test", "street2": "", "city": "los angeles", "zip": "90210", "countryId": "US", "regionId": "12", "region": null, "regionCode": "CA", "billingUseShipping": "1", "billingTelephone": "4025555555", "billingFax": null, "billingStreetFull": "", "billingStreet1": "", "billingStreet2": "", "billingCity": "", "billingZip": null, "billingCountryId": "", "billingRegionId": null, "billingRegion": null, "billingRegionCode": null, "status": "A", "carrierCode": "flatrate", "urlKey": "vendor1", "createdAt": "2021-01-05 20:09:54", "vacationMode": "0", "vacationEnd": null, "vacationMessage": null, "accountType": null, "isFeatured": "0", "ratingSummary": "0.00 (0)" }, { "vendorId": "2", "vendorName": "vendor2", "vendorAttn": "", "email": "wtsergo.test+v2@gmail.com", "telephone": "4025555555", "fax": null, "streetFull": "14 elmwood st ne", "street1": "14 elmwood st ne", "street2": "", "city": "rome", "zip": "30161", "countryId": "US", "regionId": "19", "region": null, "regionCode": "GA", "billingUseShipping": "1", "billingTelephone": "4025555555", "billingFax": null, "billingStreetFull": "", "billingStreet1": "", "billingStreet2": "", "billingCity": "", "billingZip": null, "billingCountryId": "", "billingRegionId": null, "billingRegion": null, "billingRegionCode": null, "status": "A", "carrierCode": "flatrate", "urlKey": "vendor2", "createdAt": "2021-01-05 20:09:54", "vacationMode": "0", "vacationEnd": null, "vacationMessage": null, "accountType": null, "isFeatured": null, "ratingSummary": "0.00 (0)" }, { "vendorId": "3", "vendorName": "vendor3", "vendorAttn": "", "email": "wtsergo.test+v3@gmail.com", "telephone": "4025555555", "fax": null, "streetFull": "Bride Path", "street1": "Bride Path", "street2": "", "city": "Mantoloking", "zip": "44025", "countryId": "US", "regionId": "47", "region": null, "regionCode": "OH", "billingUseShipping": "1", "billingTelephone": "4025555555", "billingFax": null, "billingStreetFull": "", "billingStreet1": "", "billingStreet2": "", "billingCity": "", "billingZip": null, "billingCountryId": "", "billingRegionId": null, "billingRegion": null, "billingRegionCode": null, "status": "A", "carrierCode": "flatrate", "urlKey": null, "createdAt": "2021-02-16 07:47:41", "vacationMode": "0", "vacationEnd": null, "vacationMessage": null, "accountType": null, "isFeatured": "0", "ratingSummary": "0.00 (0)" } ] } }
Example:
{ vendor(id: 1) { vendorId vendorName vendorAttn email telephone fax streetFull street1 street2 city zip countryId regionId region regionCode billingUseShipping billingTelephone billingFax billingStreetFull billingStreet1 billingStreet2 billingCity billingZip billingCountryId billingRegionId billingRegion billingRegionCode status carrierCode urlKey createdAt vacationMode vacationEnd vacationMessage accountType isFeatured ratingSummary } }
RESPONSE
{ "data": { "vendor": { "vendorId": "1", "vendorName": "vendor1", "vendorAttn": "", "email": "wtsergo.test+v1@gmail.com", "telephone": "4025555555", "fax": null, "streetFull": "1234 Test", "street1": "1234 Test", "street2": "", "city": "los angeles", "zip": "90210", "countryId": "US", "regionId": "12", "region": null, "regionCode": "CA", "billingUseShipping": "1", "billingTelephone": "4025555555", "billingFax": null, "billingStreetFull": "", "billingStreet1": "", "billingStreet2": "", "billingCity": "", "billingZip": null, "billingCountryId": "", "billingRegionId": null, "billingRegion": null, "billingRegionCode": null, "status": "A", "carrierCode": "flatrate", "urlKey": "vendor1", "createdAt": "2021-01-05 20:09:54", "vacationMode": "0", "vacationEnd": null, "vacationMessage": null, "accountType": null, "isFeatured": "0", "ratingSummary": "0.00 (0)" } } }
It's a shorthand of general magento products query.
Example:
{ vendorProducts(vendorId:3, filter: { price: { from: "28" to: "30"} } ) { total_count items { name sku description { html } price_range { maximum_price { regular_price { value } } } } } }
RESPONSE
{ "data": { "vendorProducts": { "total_count": 2, "items": [ { "name": "Overnight Duffle", "sku": "24-WB07", "description": { "html": "<p>For long weekends away, camping outings and business trips, the Overnight Duffle can't be beat. The dual handles make it a cinch to carry, while the durable waterproof exterior helps you worry less about the weather. With multiple organizational pockets inside and out, it's the perfect travel companion.</p>\r\n<ul>\r\n<li>Dual top handles.</li>\r\n<li>W 15\" x H 15\" x D 9\".</li>\r\n</ul>" }, "price_range": { "maximum_price": { "regular_price": { "value": 45 } } } }, { "name": "Push It Messenger Bag", "sku": "24-WB04", "description": { "html": "<p>The name says so, but the Push It Messenger Bag is much more than a busy commuter's tote. It's a closet away from home when you're pedaling from class or work to gym and back or home again. It's the perfect size and shape for laptop, folded clothes, even extra shoes.</p>\r\n<ul>\r\n<li>Adjustable crossbody strap.</li>\r\n<li>Top handle.</li>\r\n<li>Zippered interior pocket.</li>\r\n<li>Secure clip closures.</li>\r\n<li>Durable fabric construction.</li>\r\n</ul>" }, "price_range": { "maximum_price": { "regular_price": { "value": 45 } } } } ] } } }
Example:
{ vendorProductOffers(sku: "24-WB04") { vendorProductId vendorId productId priority vendorSku vendorCost stockQty backorders status shippingPrice vendorTitle state stateDescr freeshipping vendorPrice specialPrice specialFromDate specialToDate } }
RESPONSE
{ "data": { "vendorProductOffers": [ { "vendorProductId": "15", "vendorId": "1", "productId": "14", "priority": null, "vendorSku": null, "vendorCost": null, "stockQty": "99", "backorders": "-1", "status": "1", "shippingPrice": null, "vendorTitle": null, "state": "new", "stateDescr": null, "freeshipping": "0", "vendorPrice": "187.86", "specialPrice": null, "specialFromDate": null, "specialToDate": null }, { "vendorProductId": "6171", "vendorId": "2", "productId": "14", "priority": null, "vendorSku": null, "vendorCost": null, "stockQty": "20", "backorders": "-1", "status": "1", "shippingPrice": null, "vendorTitle": null, "state": "new", "stateDescr": null, "freeshipping": "0", "vendorPrice": "1287.86", "specialPrice": null, "specialFromDate": null, "specialToDate": null }, { "vendorProductId": "6174", "vendorId": "3", "productId": "14", "priority": null, "vendorSku": null, "vendorCost": null, "stockQty": "30", "backorders": "-1", "status": "1", "shippingPrice": null, "vendorTitle": null, "state": "new", "stateDescr": null, "freeshipping": "0", "vendorPrice": "290", "specialPrice": null, "specialFromDate": null, "specialToDate": null } ] } }