graycore/magento2-orders-graphql

This package is abandoned and no longer maintained. No replacement package was suggested.

A Magento 2 module that adds a fully featured GraphQL orders endpoint.

Maintainers

Package info

github.com/graycoreio/magento2-orders-graphql

Type:magento2-module

pkg:composer/graycore/magento2-orders-graphql

Fund package maintenance!

graycoreio

Statistics

Installs: 149

Dependents: 0

Suggesters: 0

Stars: 1

Open Issues: 0

v0.3.1 2020-10-13 23:27 UTC

This package is auto-updated.

Last update: 2020-11-13 23:46:03 UTC


README

Build Status

A Magento 2 module that adds a fully featured GraphQL orders endpoint.

Note that this is scheduled to be obsolete and deprecated in Magento 2.4.1 given that an officially maintained GraphQL order module will be released.

Installation

composer require graycore/magento2-orders-graphql

Usage

Guest Orders

For guest carts, use the graycoreGuestOrders query and pass in the cart ID as cartId:

query GetGuestOrders {
  graycoreGuestOrders(cartId: "dsfg67dsfg65sd6fgs8dhffdgs") {
    orders {
      id
    }
  }
}

Customer Orders

For customer carts, use the graycoreCustomerOrders query. There is an optional orderNumber parameter which will return a specific order. Not passing orderNumber will return all of the authenticated customer's orders. Authenticate the customer according to normal Magento procedures.

query GetCustomerOrders {
  graycoreCustomerOrders(
    orderNumber: "0000000001"
  ) {
    orders {
      id
    }
  }
}

Schema

Refer to the GraphQL schema for documentation about the types available in the queries.