- Subscribe to RSS Feed
- Mark Thread as New
- Mark Thread as Read
- Float this Thread for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
How to use Transactions API over HTTP?
Hi all, I'm successfully using the "Connect API" by simply doing a POST to https://connect.squareup.com/v2/locations/{'square_locid'}/transactions.
I'd like to start using the "Transactions API" for some repeat transactions, but they don't seem to have any code examples for HTTP or curl... instead just what appears to be malformed code samples in PHP 5.5 (which is end-of-life so nobody can run it ?????). I'm referring to the docs here: https://developer.squareup.com/docs/transactions-api/build-with-transactions
Are there any proper tutorials anywhere? Our server-side code is in Perl. I'm comfortable doing HTTP POST and JSON but I can't use a PHP 5.5 SDK.
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report
- Subscribe to RSS Feed
- Mark Thread as New
- Mark Thread as Read
- Float this Thread for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
Hey @fdsjkalfjdaslkf. I checked in with an API specialist for you and they confirmed that you can this by setting upSquare Payment Form in order to generate a nonce to charge a transaction.
Then, in order to use HTTP, review our docs here to see what headers and parameters need to be set: https://developer.squareup.com/docs/api/connect/v2#buildwithrest. The parameters and endpoint to charge a transaction using HTTP can be found here: https://developer.squareup.com/docs/api/connect/v2#endpoint-transactions-charge
But in order to repeat transactions you'll need to save a card on file so you can charge the card on file in future. There isn't a way to process recurring charges with Square's API at this time so you'd need to charge the card as needed.
Seller Community Manager
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report