{"id":21304769,"url":"https://github.com/fidele-software-solutions/capacitor-paystack","last_synced_at":"2025-10-15T06:28:35.125Z","repository":{"id":48925582,"uuid":"263342273","full_name":"Fidele-Software-Solutions/capacitor-paystack","owner":"Fidele-Software-Solutions","description":"A Paystack capacitor plugin for Android and iOS","archived":false,"fork":false,"pushed_at":"2022-02-17T22:45:57.000Z","size":1933,"stargazers_count":4,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-05T05:41:57.356Z","etag":null,"topics":["android","angular","capacitor","capacitor-plugin","ionic","ios","javascript","paystack","paystack-android","paystack-ios","paystack-sdk","react","typescript","vue"],"latest_commit_sha":null,"homepage":"","language":"Objective-C","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/Fidele-Software-Solutions.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}},"created_at":"2020-05-12T13:18:56.000Z","updated_at":"2023-03-24T08:08:31.000Z","dependencies_parsed_at":"2022-09-26T20:21:31.628Z","dependency_job_id":null,"html_url":"https://github.com/Fidele-Software-Solutions/capacitor-paystack","commit_stats":null,"previous_names":["bot101/capacitor-paystack"],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fidele-Software-Solutions%2Fcapacitor-paystack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fidele-Software-Solutions%2Fcapacitor-paystack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fidele-Software-Solutions%2Fcapacitor-paystack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Fidele-Software-Solutions%2Fcapacitor-paystack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Fidele-Software-Solutions","download_url":"https://codeload.github.com/Fidele-Software-Solutions/capacitor-paystack/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247294463,"owners_count":20915338,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["android","angular","capacitor","capacitor-plugin","ionic","ios","javascript","paystack","paystack-android","paystack-ios","paystack-sdk","react","typescript","vue"],"created_at":"2024-11-21T16:15:54.030Z","updated_at":"2025-10-15T06:28:30.077Z","avatar_url":"https://github.com/Fidele-Software-Solutions.png","language":"Objective-C","readme":"# Paystack Capacitor Plugin\nA Paystack capacitor plugin for Android and iOS\n\n## Getting Started\n\nThis plugin enables seamless integration of the [Paystack SDK](https://github.com/PaystackHQ/paystack-android) into a [Capacitor](https://capacitor.ionicframework.com/) application.\n\n### Installation\n\nTo install this plugin, run the NPM command below in your Capacitor project's root folder\n```\nnpm i capacitor-paystack-plugin\n```\n\nThen open your project in Android Studio with\n```\nnpx cap open android\n```\n\nor XCode with\n```\nnpx cap open ios\n```\n\n### Configuration\nIn your Android Studio project, add the following line to the list of plugins in your project, if any\n```\n...\nadd(PaystackCapacitor.class);\n```\n\nIn your project folder, run the command below to update your Android Studio/XCode project\n```\nnpx cap sync\n```\n\nSetup complete!\n\n### Code example\nTo charge a card, \n```\n//Import the paystack plugin\nimport { PaystackPlugin } from '@bot101/capacitor-paystack-plugin';\n\n//Create a paystack object\nconst paystack: PaystackPlugin; = new PaystackPlugin();\n\n//Initialize the SDK with your Paystack public key (found in your Paystack developer account dashboard)\nawait this.paystack.initialize({publicKey: \"pk_public key here\"});\n\n//Add customer card information\nawait this.paystack.addCard({\n  cardNumber: String(cardNumber),\n  expiryMonth: String(expiryMonth),\n  expiryYear: String(expiryYear),\n  cvv: String(cvv)\n});\n\n//Add the email to charge\nawait this.paystack.setChargeEmail({email: \"email@address.com\"});\n\n//Set the amount to charge the card (in kobo)\nawait this.paystack.setChargeAmount({amount: '1000000'});\n\n//Optionally add custom fields, metadata and charge parameters (more information in the Paystack docs)\nawait this.paystack.putChargeCustomFields({customField1: \"field1\", customField2: \"field2\"});\nawait this.paystack.putChargeMetadata({metaData1: \"meta1\", metaData2: \"meta2\"});\nawait this.paystack.addChargeParameters({param1: \"param1\", param2: \"param2\"});\n\n//Call chargeCard to charge the card\nconst chargeResponse = await this.paystack.chargeCard();\nreturn chargeResponse.reference;\n```\n\nTo charge an access code\n\n```\n//After initializing the plugin as detailed above\n\n//Add customer card information\nawait this.paystack.addCard({\n  cardNumber: String(cardNumber),\n  expiryMonth: String(expiryMonth),\n  expiryYear: String(expiryYear),\n  cvv: String(cvv)\n});\n\n//Set the access code retrieved from your web server\nawait this.paystack.setAccessCode({accessCode});\n\n//Call chargeCard to charge the card\nconst chargeResponse = await this.paystack.chargeCard();\nreturn chargeResponse.reference;\n```\n\nTo get a card type\n```\nconst cardInfo = await this.paystack.getCardType()\nconsole.log(cardInfo.card_type) //\"Visa\", \"Mastercard\", e.t.c\n```\n## Note\nNone\n\n## Running the tests\nTests are not yet setup\n\n## Deployment\nBuild your application and you are good to go!\n\n## Versioning\nYet to setup\n\n## Author\n\n* **Okafor Ikenna** - [Github](https://bot101.github.io)\n## License\n\nThis project is licensed under the MIT License\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffidele-software-solutions%2Fcapacitor-paystack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffidele-software-solutions%2Fcapacitor-paystack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffidele-software-solutions%2Fcapacitor-paystack/lists"}