{"id":36316256,"url":"https://github.com/contitouchtechnologies/php-contipay-libray","last_synced_at":"2026-01-11T11:02:41.342Z","repository":{"id":56957656,"uuid":"460047012","full_name":"contitouchtechnologies/php-contipay-libray","owner":"contitouchtechnologies","description":"ContiPay PHP Client","archived":false,"fork":false,"pushed_at":"2024-04-30T11:45:00.000Z","size":63,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-04-30T13:19:41.222Z","etag":null,"topics":["contipay","contipay-payment-gateway","zimbabwe"],"latest_commit_sha":null,"homepage":"https://packagist.org/packages/nigel/contipay-php","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/contitouchtechnologies.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2022-02-16T14:48:26.000Z","updated_at":"2024-04-30T11:43:19.000Z","dependencies_parsed_at":"2024-03-11T15:46:08.422Z","dependency_job_id":"eca22eaa-e9b7-482e-9b93-f15a88a55043","html_url":"https://github.com/contitouchtechnologies/php-contipay-libray","commit_stats":{"total_commits":12,"total_committers":1,"mean_commits":12.0,"dds":0.0,"last_synced_commit":"c8dd984804ef0dda024498201bcffaddd24ed1eb"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/contitouchtechnologies/php-contipay-libray","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/contitouchtechnologies%2Fphp-contipay-libray","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/contitouchtechnologies%2Fphp-contipay-libray/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/contitouchtechnologies%2Fphp-contipay-libray/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/contitouchtechnologies%2Fphp-contipay-libray/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/contitouchtechnologies","download_url":"https://codeload.github.com/contitouchtechnologies/php-contipay-libray/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/contitouchtechnologies%2Fphp-contipay-libray/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28301326,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-11T08:21:30.231Z","status":"ssl_error","status_checked_at":"2026-01-11T08:21:26.882Z","response_time":60,"last_error":"SSL_read: 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":["contipay","contipay-payment-gateway","zimbabwe"],"created_at":"2026-01-11T11:02:41.269Z","updated_at":"2026-01-11T11:02:41.321Z","avatar_url":"https://github.com/contitouchtechnologies.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ContiPay PHP Client Documentation\n\n## Requirements\n\n1. ContiPay Account\n\n2. ContiPay Secret and Key\n\n## How it Works\n\n### 1. Install latest with Composer\n\n```bash\ncomposer require nigel/contipay-php\n```\n\n### 2. Require Autoload File and Classes Imports\n\n```php\n\u003c?php\nuse Contipay\\Core\\Contipay;\nuse Contipay\\Helpers\\Payload\\PayloadGenerator;\n\nrequire_once __DIR__ . '/vendor/autoload.php';\n\n\n$webhookUrl = \"https://www.contipay.co.zw/api/webhook\";\n$successUrl = \"https://www.contipay.co.zw/api/success\";\n$cancelUrl = \"https://www.contipay.co.zw/api/cancel\";\n$merchantCode = 00;\n$phone = \"2637****340\";\n$amount = (float) 10;\n\n$contipay = new Contipay(\n    'token-here', // copy from .env or paste directly\n    'secret-here', // copy from .env or paste directly\n);\n```\n\n### 3. Process Payment\n\n#### i. Basic Direct Payment Example\n\n```php\n\n$payload = (new PayloadGenerator($merchantCode, $webhookUrl))\n    -\u003esetUpProviders('InnBucks', 'IB')\n    -\u003esimpleDirectPayload(\n        $amount,\n        $phone,\n    );\n\n$res = $contipay-\u003esetAppMode(\"DEV\")\n    -\u003esetPaymentMethod()\n    -\u003eprocess($payload);\n\nheader('Content-type: application/json');\n\necho $res;\n```\n\n#### ii. Basic Redirect Payment Example\n\n```php\n\n$payload = (\n    new PayloadGenerator(\n        $merchantCode,\n        $webhookUrl,\n        $successUrl,\n        $cancelUrl\n    )\n)-\u003esimpleRedirectPayload(\n        $amount,\n        $phone\n    );\n\n$res = $contipay-\u003esetAppMode(\"DEV\")\n    -\u003esetPaymentMethod('redirect')\n    -\u003eprocess($payload);\n\nheader('Content-type: application/json');\n\necho $res;\n```\n\n#### iii. Direct Payment Example\n\n```php\n\n$payload = (\n    new PayloadGenerator(\n        $merchantCode,\n        $webhookUrl\n    )\n)-\u003esetUpCustomer('Nigel', 'Jaure', $phone, 'ZW', 'nigeljaure@gmail.com')\n    -\u003esetUpProviders('Ecocash', 'EC')\n    -\u003esetUpAccountDetails($phone, 'Nigel Jaure')\n    -\u003esetUpTransaction($amount, \"USD\")\n    -\u003edirectPayload();\n\n$res = $contipay\n    -\u003esetAppMode(\"DEV\")\n    -\u003esetPaymentMethod()\n    -\u003eprocess($payload);\n\nheader('Content-type: application/json');\n\necho $res;\n```\n\n#### iv. Redirect Payment Example\n\n```php\n$payload = (\n    new PayloadGenerator(\n        $merchantCode,\n        $webhookUrl,\n        $successUrl,\n        $cancelUrl\n    )\n)-\u003esetUpCustomer('Nigel', 'Jaure', $phone, 'ZW', 'nigeljaure@gmail.com')\n    -\u003esetUpTransaction($amount, \"USD\")\n    -\u003eredirectPayload();\n\n$res = $contipay-\u003esetAppMode(\"DEV\")\n    -\u003esetPaymentMethod('redirect')\n    -\u003eprocess($payload);\n\nheader('Content-type: application/json');\n\necho $res;;\n```\n\n### 4. Disburse Payment\n\n```php\n\n$privateKey = \u003c\u003c\u003cEOD\n-----BEGIN PRIVATE KEY-----\n     YOUR KEY HERE \n-----END PRIVATE KEY-----\nEOD;\n\n$payload = (\n    new PayloadGenerator(\n        $merchantCode,\n        $webhookUrl\n    )\n)-\u003esetUpCustomer('Nigel', 'Jaure', $phone, 'ZW', 'nigeljaure@gmail.com')\n    -\u003esetUpProviders('Transfer', 'TF')\n    -\u003esetUpAccountDetails($phone, 'Nigel Jaure')\n    -\u003esetUpTransaction($amount, \"USD\")\n    -\u003edirectPayload();\n\n$res = $contipay\n    -\u003esetAppMode(\"DEV\")\n    -\u003esetPaymentMethod()\n    -\u003edisburse($payload, $privateKey);\n\nheader('Content-type: application/json');\n\necho $res;\n```\n\n## Additional Notes\n\n- The `updateURL` method is optional and applicable only if the URL has changed. Use it to update the URLs accordingly. Here's how you can use it:\n\n```php\n$contipay = new Contipay(\n    'token-here', // copy from .env or paste directly\n    'secret-here', // copy from .env or paste directly\n);\n\n// Update URLs if necessary\n$contipay-\u003eupdateURL('dev-url', 'live-url');\n\n// Process payment with the updated URLs\n$res = $contipay\n    -\u003esetAppMode(\"DEV\")  // LIVE as another option\n    -\u003esetPaymentMethod()\n    -\u003eprocess($payload);\n\nheader('Content-type: application/json');\n\necho $res;\n```\n\n- Ensure to set the appropriate mode (`DEV` or `LIVE`) using the `setAppMode` method before processing payments.\n\n- The provided examples cover basic scenarios, including direct and redirect payment methods, customer information setup, and transaction details.\n\n- ContiPay JavaScript Alternative [here](https://github.com/njzw/contipay-js-client)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcontitouchtechnologies%2Fphp-contipay-libray","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcontitouchtechnologies%2Fphp-contipay-libray","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcontitouchtechnologies%2Fphp-contipay-libray/lists"}