{"id":36407130,"url":"https://github.com/paytrail/paytrail-php-sdk","last_synced_at":"2026-03-05T09:04:44.181Z","repository":{"id":37766832,"uuid":"402378395","full_name":"paytrail/paytrail-php-sdk","owner":"paytrail","description":"PHP Software Development Kit for Paytrail payment service","archived":false,"fork":false,"pushed_at":"2025-12-16T13:00:42.000Z","size":548,"stargazers_count":10,"open_issues_count":1,"forks_count":14,"subscribers_count":7,"default_branch":"master","last_synced_at":"2026-01-23T21:14:49.230Z","etag":null,"topics":["paytrail","php","sdk"],"latest_commit_sha":null,"homepage":"https://www.paytrail.com","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/paytrail.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2021-09-02T10:23:43.000Z","updated_at":"2025-12-16T12:58:36.000Z","dependencies_parsed_at":"2023-02-18T04:15:59.471Z","dependency_job_id":"fa39e6a7-2163-426a-b950-92aaf129fd3b","html_url":"https://github.com/paytrail/paytrail-php-sdk","commit_stats":{"total_commits":168,"total_committers":12,"mean_commits":14.0,"dds":0.6547619047619048,"last_synced_commit":"f9c3f0458a84ed612398ee77c82f011caef57ef5"},"previous_names":[],"tags_count":23,"template":false,"template_full_name":null,"purl":"pkg:github/paytrail/paytrail-php-sdk","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paytrail%2Fpaytrail-php-sdk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paytrail%2Fpaytrail-php-sdk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paytrail%2Fpaytrail-php-sdk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paytrail%2Fpaytrail-php-sdk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/paytrail","download_url":"https://codeload.github.com/paytrail/paytrail-php-sdk/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paytrail%2Fpaytrail-php-sdk/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30117501,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-05T08:19:04.902Z","status":"ssl_error","status_checked_at":"2026-03-05T08:17:37.148Z","response_time":93,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["paytrail","php","sdk"],"created_at":"2026-01-11T16:44:50.421Z","updated_at":"2026-03-05T09:04:43.074Z","avatar_url":"https://github.com/paytrail.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Paytrail PHP-SDK\nPHP Software Development Kit for [Paytrail](https://www.paytrail.com) payment service\n\n## Paytrail Payment Service\n\nPaytrail is a payment gateway that offers 20+ payment methods for Finnish customers.\n\nThe payment gateway provides all the popular payment methods with one simple integration. The provided payment methods include, but are not limited to, credit cards, online banking and mobile payments.\n\nTo use the payment service, you need to sign up for a Paytrail account. Transaction fees will be charged for every transaction. Transaction cost may vary from merchant to merchant, based on what is agreed upon with Paytrail when negotiating your contract. For more information and registration, please visit our [website](https://www.paytrail.com) or contact asiakaspalvelu@paytrail.com directly.\n\n## Requirements\n\n### General requirements\n\n- PHP version \u003e= 7.3\n- ext-curl PHP cURL extension\n- ext-json PHP JSON extension\n\n### Development requirements\n\n- [PHPUnit](https://github.com/sebastianbergmann/phpunit) - A programmer-oriented testing framework for running unit tests in PHP.\n- [Guzzle](https://github.com/guzzle/guzzle) 7 or 6 - PHP HTTP client for performing HTTP request.\n\n### Guzzle\nPHP-SDK will use Guzzle 6 or 7, if in present application, otherwise it will fall back to cURL. Guzzle is still used as dev dependency to make testing easier.\n\nUsing Guzzle is recommended on applications using PHP-SDK.\n\n## Installation\n\nInstall with Composer:\n\n```\ncomposer require paytrail/paytrail-php-sdk\n```\n\nThe package uses PSR-4 autoloader. Activate autoloading by requiring the Composer autoloader:\n\n```\nrequire 'vendor/autoload.php';\n```\n\n_Note the path to the vendor directory is relative to your project._\n\n## Folder contents \u0026 descriptions\n\n| Folder/File    | Content/Description                                                      |\n|----------------|--------------------------------------------------------------------------|\n| examples       | Examples                                                                 |\n| src/Exception  | Exception classes and functions                                          |\n| src/Interfaces | Interface classes and functions for all the related classes to implement |\n| src/Model      | Model classes and functions                                              |\n| src/Request    | Request classes and functions                                            |\n| src/Response   | Response classes and functions                                           |\n| src/Util       | Utility/trait classes and functions                                      |\n| src/Client.php | Client class and functions                                               |\n| tests/unit     | PHP unit tests                                                           |\n\n## Basic functionalities\n\nThe Paytrail PHP-SDK supports most of the functionalities of the [Paytrail Payment API](https://paytrail.github.io/api-documentation/#/).\n\nSome of the key features are:\n\n### Payments and refunds\n\n- [Creating payment request](https://paytrail.github.io/api-documentation/#/?id=create)\n- [Creating payment status request](https://paytrail.github.io/api-documentation/#/?id=get)\n- [Creating refund request](https://paytrail.github.io/api-documentation/#/?id=refund)\n\n### Tokenized credit cards and payments\n\n- [Creating Add card form request](https://paytrail.github.io/api-documentation/#/?id=adding-tokenizing-cards)\n- [Creating Get token request](https://paytrail.github.io/api-documentation/#/?id=get-token)\n- [Creating Customer Initiated Transactions (CIT) or Merchant Initiated Transactions (MIT)](https://checkoutfinland.github.io/psp-api/#/?id=charging-a-token)\n\n### Shop-in-Shop\n\n- Creating Shop-in-Shop payment request\n\n### Settlements\n\n- [Requesting merchant settlements](https://docs.paytrail.com/#/?id=settlements)\n\n### Reports\n\n- [Request payment report](https://docs.paytrail.com/#/?id=payment-report-request)\n\n## Methods\n\nList of `Client::class` methods\n\n| Method                              | Description                                          |\n|-------------------------------------|------------------------------------------------------|\n| getPaymentProviders()               | Get a list of payment providers                      |\n| getGroupedPaymentProviders()        | Returns an array of grouped payment providers fields |\n| createPayment()                     | Create payment                                       |\n| createShopInShopPayment()           | Create SiS payment                                   |\n| getPaymentStatus()                  | Request payment status                               |\n| refund()                            | Create refund                                        |\n| emailRefund()                       | Create email refund                                  |\n| createAddCardFormRequest()          | Save card details                                    |\n| createGetTokenRequest()             | Request card token                                   |\n| createCitPaymentCharge()            | Create CiT payment                                   |\n| createCitPaymentAuthorizationHold() | Create CiT authorization hold                        |\n| createCitPaymentCommit()            | Commit CiT authorization hold                        |\n| createMitPaymentCharge()            | Create MiT payment                                   |\n| createMitPaymentAuthorizationHold() | Create MiT authorization hold                        |\n| createMitPaymentCommit()            | Commit MiT authorization hold                        |\n| revertPaymentAuthorizationHold()    | Revert existing Mit or CiT authorization hold        |\n| activateInvoice()                   | Activate pending invoice (Walley / Klarna)           |\n| cancelInvoice()                     | Cancel pending invoice (Currently only Klarna)       |\n| getSettlements() [Deprecated]       | Deprecated Request settlements                       |\n| requestSettlements()                | Request settlements                                  |\n| requestPaymentReport()              | Request payment report                               |\n| requestPaymentReportBySettlement()  | Request payment report by settlement ID              |\n| createPaymentAndAddCard()           | Create payment and save card details                 |\n\n\n---\n\n**_Disclaimer:_** *This open source project is made available to assist coders in getting started with our API. However, we do not provide any warranty or guarantee that the code will work as intended and offer limited support for it. Use at your own risk.*\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpaytrail%2Fpaytrail-php-sdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpaytrail%2Fpaytrail-php-sdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpaytrail%2Fpaytrail-php-sdk/lists"}