Code Monkey home page Code Monkey logo

ingrid-checkout-siw-client's Introduction

Ingrid Delivery Checkout v2 [OpenAPIClient-php]

Delivery Checkout provides almost unlimited flexibility in selecting delivery options while securing that the process is as convenient and as fast as it physically can. ⚡

Command to generate API client

$ openapi-generator-cli generate \
            -i https://api.ingrid.com/v1/delivery_checkout/_/swagger.json \
            -g php \
            -o siw

By default openapi-generator-cli generates OpenAPI client for the latest version of Guzzle. To prevent it use older version of openapi-generator-cli:

nvm use 18
npm install @openapitools/openapi-generator-cli -g
openapi-generator-cli version-manager set 5.2.1
openapi-generator-cli generate \
            -i https://api.ingrid.com/v1/delivery_checkout/_/swagger.json \
            -g php \
            -o siw

Installation & Usage

Requirements

PHP 7.3 and later. Should also work with PHP 8.0 but has not been tested.

Installation

composer require centrahq/ingrid-checkout-siw-client

API Endpoints

All URIs are relative to http://localhost/v1/delivery_checkout

Class Method HTTP request Description
DefaultApi deliveryCheckoutCompleteSession POST /session.complete When the customer completes the purchase you also need to complete the session. At this point you will have to supply us with the address and the contact details of the user.
DefaultApi deliveryCheckoutCreateSession POST /session.create To add the Ingrid widget to the checkout page you will need to create a new session. This can be done by this call. When doing this you will need to provide some required information.
DefaultApi deliveryCheckoutGetSession GET /session.get Fetches a session by ID. Can be used for loading a previously created session that have been stored together with a customer's shopping cart from a previous visit. It can contain obsolete data. To get the session with the freshest data, use /session.pull endpoint.
DefaultApi deliveryCheckoutListSessionsSummaries GET /sessions_summaries.list Allows the merchant to get shipping data (session IDs and result fields) associated with tos ID.
DefaultApi deliveryCheckoutPullSession GET /session.pull Pulls a session by ID. Can be used for loading a previously created session that have been stored together with a customer's shopping cart from a previous visit. Session will be refreshed if its in active state and if configuration has changed or delivery promise expires.
DefaultApi deliveryCheckoutUpdateSession POST /session.update Update the session with new information. Useful for cases where the customer or cart information is changed. The later being the most common case.

Models

Authorization

Bearer

  • Type: API key
  • API key parameter name: Authorization
  • Location: HTTP header

Tests

To run the tests, use:

composer install
vendor/bin/phpunit

Author

About this package

This PHP package is automatically generated by the OpenAPI Generator project:

  • API version: 1.0
  • Build package: org.openapitools.codegen.languages.PhpClientCodegen

ingrid-checkout-siw-client's People

Contributors

an-adamchuk avatar

Watchers

Daniel (dmilith) Dettlaff avatar Frans Rosén avatar Jacek Symonowicz avatar  avatar Bruno avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.