Git Product home page Git Product logo

php_sdk's Introduction

Riskified PHP SDK

See samples/ for examples on how to use this SDK.

Migrating to API Version 2

API Version 2 introduces new features (and breaks some old ones).

Order Webhook

This version represents a shift from data-driven order handling to multiple API endpoints, each designed for a specific purpose. These include:

  • /api/create - served by $transport->createOrder()
  • /api/update - served by $transport->updateOrder()
  • /api/submit - served by $transport->submitOrder()
  • /api/refund - served by $transport->refundOrder()
  • /api/cancel - served by $transport->cancelOrder()

Refer to the online documentation for more details. When migrating from version 1, you'll need to separate the different calls to Riskified's API to support this new process.

Decision Notifications

Constructor $headers argument format

The format of the $headers argument when constructing a new Riskified\DecisionNotification\Notification instance has changed. The constructor now expects an associative array of all the HTTP headers of the request, and not a flat array of strings, as in previous versions of this SDK.

This change should simplify integration since the argument now follows the format of the return value of the popular PHP/Apache function getallheaders().

API v2 payload format

Notification requests in API version 2 now contain a JSON encoded payload which is more flexible and easily extended.

If you are already using the Notification class in version 1, there are no additional actions required to support the migration to JSON, as this SDK handles the new data format seamlessly.

php_sdk's People

Contributors

erezsela avatar riskx avatar itaywaxman avatar eyal1 avatar rich-spitkovsky-riskified avatar dbarond avatar arungopalrf avatar pm-gm avatar chadsmithbhn avatar mooseriskified avatar bobmeow avatar stephenjwinn avatar dodsoftware avatar jchiupro 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.