Skip to Content
Odoo Menu
  • Sign in
  • Try it free
  • Apps
    Finance
    • Accounting
    • Invoicing
    • Expenses
    • Spreadsheet (BI)
    • Documents
    • Sign
    Sales
    • CRM
    • Sales
    • POS Shop
    • POS Restaurant
    • Subscriptions
    • Rental
    Websites
    • Website Builder
    • eCommerce
    • Blog
    • Forum
    • Live Chat
    • eLearning
    Supply Chain
    • Inventory
    • Manufacturing
    • PLM
    • Purchase
    • Maintenance
    • Quality
    Human Resources
    • Employees
    • Recruitment
    • Time Off
    • Appraisals
    • Referrals
    • Fleet
    Marketing
    • Social Marketing
    • Email Marketing
    • SMS Marketing
    • Events
    • Marketing Automation
    • Surveys
    Services
    • Project
    • Timesheets
    • Field Service
    • Helpdesk
    • Planning
    • Appointments
    Productivity
    • Discuss
    • Artificial Intelligence
    • IoT
    • VoIP
    • Knowledge
    • WhatsApp
    Third party apps Odoo Studio Odoo Cloud Platform
  • Industries
    Retail
    • Book Store
    • Clothing Store
    • Furniture Store
    • Grocery Store
    • Hardware Store
    • Toy Store
    Food & Hospitality
    • Bar and Pub
    • Restaurant
    • Fast Food
    • Guest House
    • Beverage Distributor
    • Hotel
    Real Estate
    • Real Estate Agency
    • Architecture Firm
    • Construction
    • Property Management
    • Gardening
    • Property Owner Association
    Consulting
    • Accounting Firm
    • Odoo Partner
    • Marketing Agency
    • Law firm
    • Talent Acquisition
    • Audit & Certification
    Manufacturing
    • Textile
    • Metal
    • Furnitures
    • Food
    • Brewery
    • Corporate Gifts
    Health & Fitness
    • Sports Club
    • Eyewear Store
    • Fitness Center
    • Wellness Practitioners
    • Pharmacy
    • Hair Salon
    Trades
    • Handyman
    • IT Hardware & Support
    • Solar Energy Systems
    • Shoe Maker
    • Cleaning Services
    • HVAC Services
    Others
    • Nonprofit Organization
    • Environmental Agency
    • Billboard Rental
    • Photography
    • Bike Leasing
    • Software Reseller
    Browse all Industries ⟶
  • Community
    Learn
    • Tutorials
    • Documentation
    • Certifications
    • Training
    • Blog
    • Podcast
    Empower Education
    • Education Program
    • Scale Up! Business Game
    • Visit Odoo
    Get the Software
    • Download
    • Compare Editions
    • Releases
    Collaborate
    • Github
    • Forum
    • Events
    • Translations
    • Become a Partner
    • Services for Partners
    • Register your Accounting Firm
    • Affiliate Program
    Get Services
    • Find a Partner
    • Find an Accountant
      • Get a Tailored Demo
    • Implementation Services
    • Customer References
    • Support
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +32 2 290 34 90
    • Get a Tailored Demo
  • Pricing
  • Help
  1. APPS
  2. Payment Providers
  3. REST Payment Provider v 16.0
  4. Sales Conditions FAQ

REST Payment Provider

by Awins
Odoo

$ 97.52

v 16.0 Third Party
Apps purchases are linked to your Odoo account, please sign in or sign up first.
Versions 16.0 17.0 18.0 19.0 20.0
You bought this module and need support? Click here!
Versions 16.0 17.0 18.0 19.0 20.0
  • Description
  • Manifest
  • License
Apps / Awins / api_hub_payment

REST Payment Provider

An add-on that needs API Connector Hub. One payment provider for any gateway with a hosted checkout page: you describe the create-payment request, the checkout link, the status words and the webhook in the provider form, and the customer pays on the gateway's page.

Install›Configure›Use
/odoo/action-payment.action_payment_provider/25 · REST Gateway tab
REST Payment Provider in the Odoo backend
Odoo16.0, 17.0, 18.0, 19.0, 20.0
EditionsCommunity, Enterprise
Works withAPI Connector Hub, Payment
LicenceOPL-1, 49 EUR
Tests40 automated, run on every version
Moduleapi_hub_payment

The situation

A gateway that is not in the Odoo list needs its own payment module: one for the create-payment call, one more for the webhook, and a developer to keep both working. The shop owner who only wants to take cards through a regional gateway ends up waiting for that module, or sending customers a payment link by hand and marking the invoice paid when the money shows up.

REST Payment Provider is one provider for every gateway that works the same way: your server posts a payment, the answer holds a checkout address, the customer pays there, and the gateway tells you through a webhook or the customer comes back. You fill in the request as a JSON template, point to the fields of the answer, map the gateway's status words to Odoo states, and attach a ready-made server action to a hub webhook. The key stays on the hub connection, never on the provider.

What it adds

API Connection
Login stays on the hub connection
The provider only points to an API Connector Hub connection. Base URL, key, bearer token or OAuth 2 live there, are hidden in the request log, and are not stored on the provider.
Create Session Body
JSON template with placeholders
Write the body the gateway expects and use {reference}, {amount}, {amount_minor}, {currency}, {partner_name}, {partner_email}, {return_url}, {webhook_url} and a few more. Values are escaped for JSON, so a customer called Ann "the Boss" cannot break the request. The template is checked when you save it.
Amount
Minor units for 0, 2 and 3 decimals
{amount} gives 12.50 for EUR, 1235 for JPY and 1.234 for KWD. {amount_minor} gives 1250, 1235 and 1234. Write numbers without quotes in the template.
Session Id Path
Dotted paths for the answer
Session Id Path and Redirect URL Path read the gateway's payment id and checkout address from the answer, for example session.url. The customer is sent to that address; one that is not http or https is refused.
Status Mapping
Gateway words to Odoo states
A table maps the status text of the gateway (paid, open, expired...) to Pending, Authorized, Confirmed, Canceled or Error. Case does not matter. A word that is not in the table puts the payment in Error and names the word in the message.
REST Payment: process gateway notification
Webhook through the hub
Attach this server action to a hub webhook. The hub checks the HMAC signature and ignores a repeated delivery id before the action runs. The payment is found by your reference or by the gateway's session id, at a path you choose.
Check Status
Check Status and open payments
A button on the transaction asks the status endpoint and applies the answer. The customer's return page does the same, and a scheduled action asks about payments that are still open after 10 minutes, in case a webhook never arrived.
Test Session
Test Session and API Calls
Test Session creates a one-unit session with sample values and shows the session id and link without creating a transaction. Every call is in the hub request log with the transaction reference; session and refund calls are never retried, status calls are.
Capture Path
Capture, void and refunds
Tick Capture Amount Manually and an Authorized gateway status keeps the payment Authorized in Odoo. Capture and Void send your request templates, Odoo 16 always captures the full amount, and a refused capture leaves the payment Authorized with the reason. Refund Path adds the Refund button the same way.

Getting started

Install

Open Apps, clear the Apps filter, search for REST Payment Provider and click Activate. It needs API Connector Hub and Payment. The installed provider is in test mode, unpublished and has no connection, so nothing is offered to customers until you set it up.

Apps › api_hub_payment › Activate
Configure

Create a connection for the gateway in API Hub, then open Invoicing > Configuration > Payment Providers > REST Payment Provider and fill the REST Gateway tab. If the gateway sends webhooks, add a webhook to the connection and choose the server action REST Payment: process gateway notification. Press Test Session to see the first answer. Duplicate the provider for a second gateway.

API Hub › Webhooks, and Payment Providers › REST Payment Provider › REST Gateway Settings for REST Payment Provider
Use

Customers pay on the gateway's page and come back to the standard payment status page. When a payment looks stuck, open the transaction and press Check Status, or API Calls to see each request the hub sent. Authorized payments use the standard Capture and Void buttons.

A transaction whose gateway answered with a status that is not in the table: Error, with the word in the message.
A transaction whose gateway answered with a status that is not in the table: Error, with the word in the message.
The hub request log: session calls, status calls, the signed webhook that was accepted and the one rejected with 403.
The hub request log: session calls, status calls, the signed webhook that was accepted and the one rejected with 403.

Fine print

Which gateways does it work with?
Gateways with a hosted checkout page that you reach with JSON over HTTP: a create call that returns a link, and either a webhook or a status call. It has not been tested against a live service of any vendor; you test it in test mode with your own sandbox account.
Where is the API key stored?
On the API Connector Hub connection, in a field only administrators can read. The provider form has no key or password field.
Can I take several gateways?
Yes. Duplicate the provider, choose another connection and change the templates. A webhook finds the provider through its connection.
Where can I run it?
On Odoo.sh and on your own server, Community or Enterprise, versions 16.0 to 20.0. Odoo Online doesn't accept third-party modules.
What doesn't it do?
It is configuration-driven and has not been tested against a live service of any vendor. It supports JSON requests and a redirect by GET only: no card forms on your site, no saved cards and no express checkout. With Capture Amount Manually off, a status mapped to Authorized waits as Pending. Gateways that sign the return URL, need XML or form-encoded bodies, or redirect with a POST form are not covered. A gateway that offers no status call and no webhook cannot confirm payments. Capture, void and refund requests are sent once and never retried; on Odoo 16 a refused capture shows an error message but its request is not kept in the hub log.
Can you adapt it for us?
Yes. Email odoo.expert.111@gmail.com with your Odoo version and what you'd like changed.

Log

16.0.1.0.0 · Oct 2026
First release, published for Odoo 16.0 to 20.0.

Will it fit our gateway?

Send us the create-payment example of your gateway and we will tell you how the templates would look.

Email odoo.expert.111@gmail.com
QR code: email Awins about this module

Also by Awins

API Connector Hub API Connector Hub api_connector_hub
Split Transfers Split Transfers a_stock_picking_split
Product Warranty Claims Product Warranty Claims product_warranty_claim_track
Awins builds small Odoo modules that do one job. api_hub_payment · 16.0.1.0.0
Availability
Odoo Online
Odoo.sh
On Premise
Odoo Apps Dependencies Discuss (mail)
Community Apps Dependencies Show
API Connector Hub
Lines of code 1658
Technical Name api_hub_payment
LicenseOPL-1
Odoo Proprietary License v1.0

This software and associated files (the "Software") may only be used (executed,
modified, executed after modifications) if you have purchased a valid license
from the authors, typically via Odoo Apps, or if you have received a written
agreement from the authors of the Software (see the COPYRIGHT file).

You may develop Odoo modules that use the Software as a library (typically
by depending on it, importing it and using its resources), but without copying
any source code or material from the Software. You may distribute those
modules under the license of your choice, provided that this license is
compatible with the terms of the Odoo Proprietary License (For example:
LGPL, MIT, or proprietary licenses similar to this one).

It is forbidden to publish, distribute, sublicense, or sell copies of the Software
or modified copies of the Software.

The above copyright notice and this permission notice must be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.

Please log in to comment on this module

  • The author can leave a single reply to each comment.
  • This section is meant to ask simple questions or leave a rating. Every report of a problem experienced while using the module should be addressed to the author directly (refer to the following point).
  • If you want to start a discussion with the author or have a question related to your purchase, please use the support page.
Community
  • Tutorials
  • Documentation
  • Forum
Open Source
  • Download
  • Github
  • Runbot
  • Translations
Services
  • Odoo.sh Hosting
  • Support
  • Upgrade
  • Custom Developments
  • Education
  • Find an Accountant
  • Find a Partner
  • Become a Partner
About us
  • Our company
  • Brand Assets
  • Contact us
  • Jobs
  • Events
  • Podcast
  • Blog
  • Customers
  • Legal • Privacy
  • Security

Odoo is a suite of open source business apps that cover all your company needs: CRM, eCommerce, accounting, inventory, point of sale, project management, etc.

Odoo's unique value proposition is to be at the same time very easy to use and fully integrated.

Website made with