Access to add and change pages is restricted. See: https://cwiki.apache.org/confluence/display/OFBIZ/Wiki+access

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 51 Next »

Purpose

The purpose of this document is to list the high-level API endpoints required for headless commerce(B2C). This will helps in finalizing API design.

API Endpoints

Authentication

Sr No.API EndpointDescriptionTasksStatusPhase
1POST /guest-tokenThis API will return a token for a guest account.
PlanningI
2POST /customer-tokenThis API will return a token for the registered user.
PlanningI
3POST /refresh-tokenIn case we need to update the token. As JWT token ideally contains a certain expiry time. So if the user is active then instead of getting him to log out, this API can generate a new token from the existing token.
PlanningI

Customer

Sr No.API EndpointDescriptionTasks/PRsStatusPhase
Customer Profile
1POST /customersTo register the customer.https://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
2GET /customers/{customerPartyId}To get the customer's personal information, addresses, emails, phones, etc.https://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
3PUT /customers/{customerPartyId}To update the customer's personal information.https://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
4POST /customers/reset-passwordTo get the reset password link on the registered email.https://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
5POST /customers/{customerPartyId}/change-passwordTo change the password.https://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
6GET /customers/{customerPartyId}/shipping-addressesTo get the customer's shipping addresseshttps://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
7POST /customers/{customerPartyId}/shipping-addressesTo create the shipping address.https://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
8PUT /customers/{customerPartyId}/shipping-addresses/{contactMechId}To update the shipping address.https://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
9DELETE /customers/{customerPartyId}/shipping-addresses/{contactMechId}To delete/expire the shipping address.https://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
10POST /customers/{customerPartyId}/payment-methodsTo save a payment method e.g. credit card, gift card, eft accounthttps://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
11GET /customers/{customerPartyId}/payment-methodsTo get the user's payment methods eg. saved credit cards, gift cards, eft accountshttps://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
12PUT /customers/{customerPartyId}/payment-methods/{paymentMethodId}To update the payment method detail.https://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
13DELETE /customers/{customerPartyId}/payment-methods/{paymentMethodId}To remove a saved credit card, gift card, eft account.https://github.com/apache/ofbiz-plugins/pull/45In Code ReviewI
14GET /customers/{customerPartyId}/ordersTo fetch all the orders of a customer.
In ProgressI

Catalog

Sr No.API EndpointDescriptionTasksStatusPhase
Catalog
1GET /catalogsTo get the list of catalogs.
PlanningI
2GET /catalogs/{catalogId}To get the feature categories, feature products, category hierarchy in a single call.
PlanningI
3GET /catalogs/{catalogId}/feature-categoriesTo get the feature categories of a catalog.
PlanningI
4GET  /catalogs/{catalogId}/feature-productsTo get the feature products of a catalog.
PlanningI
5GET /catalogs/{catalogId}/category-hierarchyTo get the category hierarchy of a catalog.
PlanningI
6GET /productsThis API will have support for the search string and other additional filters. This API will also bring the products of a selected category if provided.
PlanningI
7GET /products/{productId}To get the product detail.
PlanningI
8POST /products/{productId}/reviewsTo add a review of a product.
PlanningI
9GET /products/{productId}/reviewsTo get the reviews of a product.
PlanningI
10GET /products/{productId}/associated-productsTo get the list of cross-sell/upsell products.
PlanningI
11POST /products/{productId}/product-tagsTo add a tag for a product.
PlanningI
12GET /products/{productId}/product-tagsTo get all the tags of a product.
PlanningI
13GET /products/product-tagsAll the product tags for the tag cloud.
PlanningI
14GET /offersTo list the special offers
PlanningI
15GET /offers/{promotionId}To get the complete detail of a particular offer
PlanningI
16POST /sendMailFor Tell a Friend functionality
PlanningI
17POST /products/compare-listTo create a compare list and to add a product to it.
PlanningI
18GET /products/compare-listTo get the list of added products with detail for the comparison view.
PlanningI
19DELETE /products/compare-list/{productId}To remove a product from the compare list.
PlanningI

Shopping List and Quotes

Sr No.API EndpointDescriptionTasksStatusPhase
Shopping List
1POST /shopping-listsTo create a new shopping list.
PlanningI
2GET /shopping-listsTo get the list of shopping lists.
PlanningI
3GET /shopping-lists/{shoppingListId}To get the detail of a shopping list. This will also bring the list of available interval/frequency data for setting the recurrence detail using the update shopping list API.
PlanningI
4PUT /shopping-lists/{shoppingListId}To update the shopping list detail. Recurrence info can also be set from this API.
PlanningI
5POST /shopping-lists/{shoppingListId}/itemsAdd an item to the shopping list.
PlanningI
6GET /shopping-lists/{shoppingListId}/itemsGet the list of items on a shopping list.
PlanningI
7PUT /shopping-lists/{shoppingListId}/items/{itemId}Update the particular item on the shopping list.
PlanningI
8DELETE /shopping-lists/{shoppingListId}/items/{itemId}Remove the particular item from the shopping list.
PlanningI
Quote
1POST /quote-requestsQuotes Request can be created from the shopping list and from the cart.  This API will create a quote request.
PlanningI
2GET /quote-requestsTo get the list of quote requests(request history).
PlanningI
3GET /quote-requests/{requestId}To get the detail of a quote request.
PlanningI
4GET /quotesTo get the list of quotes.
PlanningI
5GET /quotes/{quoteId}To get the detail of a quote.
PlanningI
6POST /order-quotesTo create an order from the quote.
PlanningI

Shopping Cart & Checkout

Note: The below API endpoints are written considering the Object-Oriented implementation of Shopping Cart. We need to identify the best way to store the shopping cart object as the user session won't be in the picture here. One way to introduce a new table to keep the cart object with a unique cart ID. For better performance cache can also be used efficiently. The cart object should have the last updated timestamp so that a clear policy to remove the abandoned cart can be imposed.


Sr No.API EndpointDescriptionTasksStatusPhase
Shopping Cart
1POST /carts

PlanningI
2GET /carts/{cartReference}

PlanningI
3DELETE /carts/{cartReference}

PlanningI
4POST /carts/{cartReference}/itemsFor adding products and other order adjustments like shipping charges, tax, etc.
PlanningI
5GET /carts/{cartReference}/items

PlanningI
6PUT /carts/{cartReference}/items/{itemSeqId}

PlanningI
7DELETE /carts/{cartReference}/items/{itemSeqId}

PlanningI
8POST /carts/{cartReference}/promotionsTo apply the promo code on the cart.
PlanningI
9DELETE /carts/{cartReference}/promotions/{itemSeqId}To remove an applied promotion.
PlanningI
10POST /carts/{cartReference}/items/shopping-list/{shoppingListId}This will add all the items of a given shopping list to the cart.
PlanningI
11POST /carts/{cartReference}/items/order/{orderId}This will add all the items of a given past order to the cart.
PlanningI
Checkout
1POST /carts/{cartReference}/ship-groupsTo create a new ship group in case of split shipment.
PlanningI
2GET /carts/{cartReference}/ship-groupsTo get the ship groups with items.
PlanningI
3POST /carts/{cartReference}/ship-groups/{shipGroupSeqId}/shipping-addressTo add the shipping address.
PlanningI
4POST /carts/{cartReference}/ship-groups/{shipGroupSeqId}/itemsTo move items from one ship group to another in case of split shipment.
PlanningI
5POST /carts/{cartReference}/ship-groups/{shipGroupSeqId}/shipping-instructionsTo add special instructions, gift message in case of a gift, split preferences(ship all items together or ship items when available)
PlanningI
6PUT /carts/{cartReference}/ship-groups/{shipGroupSeqId}/shipping-instructionsTo update special instructions, gift message in case of a gift, split preferences(ship all items together or ship items when available)
PlanningI
7GET /shipping-methods}To get the shipping methods.
PlanningI
8POST /carts/{cartReference}/ship-groups/{shipGroupSeqId}/shipping-methodTo add/update the shipping method.
PlanningI
9GET /payment-optionsTo get the list of supported payment options.
PlanningI
10POST /carts/{cartReference}/payment-methodsTo add a payment method. The combination of the gift card and other payment methods are supported as of now.
PlanningI
11POST /checkoutTo place the order.
PlanningI
Anonymous Checkout
1POST /carts/{cartReference}/guest/personal-informationSet the anonymous user's detail for the order. Name, phone, email, etc.
PlanningI
2PUT /carts/{cartReference}/guest/personal-information

PlanningI
3POST /carts/{cartReference}/guest/shipping-address

PlanningI
4PUT /carts/{cartReference}/guest/shipping-address

PlanningI
5POST /carts/{cartReference}/guest/payment-informaion

PlanningI
6PUT /carts/{cartReference}/guest/payment-informaion

PlanningI
  • No labels