{"id":16347410,"url":"https://github.com/leebenson/paypal","last_synced_at":"2025-12-14T20:13:54.281Z","repository":{"id":57494334,"uuid":"24291426","full_name":"leebenson/paypal","owner":"leebenson","description":"PayPal Website Payments Pro API for Go (golang)","archived":true,"fork":false,"pushed_at":"2017-03-07T21:36:13.000Z","size":64,"stargazers_count":38,"open_issues_count":2,"forks_count":24,"subscribers_count":10,"default_branch":"master","last_synced_at":"2025-03-13T23:14:05.585Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","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/leebenson.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-09-21T13:18:39.000Z","updated_at":"2025-02-03T09:00:12.000Z","dependencies_parsed_at":"2022-08-27T22:40:52.056Z","dependency_job_id":null,"html_url":"https://github.com/leebenson/paypal","commit_stats":null,"previous_names":["fundary/paypal"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leebenson%2Fpaypal","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leebenson%2Fpaypal/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leebenson%2Fpaypal/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leebenson%2Fpaypal/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leebenson","download_url":"https://codeload.github.com/leebenson/paypal/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244717070,"owners_count":20498279,"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":[],"created_at":"2024-10-11T00:42:12.526Z","updated_at":"2025-12-14T20:13:48.995Z","avatar_url":"https://github.com/leebenson.png","language":"Go","funding_links":["https://developer.paypal.com/webapps/developer/docs/api/"],"categories":[],"sub_categories":[],"readme":"# Payment REST API Go client\n [![GoDoc](https://godoc.org/github.com/leebenson/paypal?status.svg)](https://godoc.org/github.com/leebenson/paypal)\n\nThis is a client for the Paypal REST API ([https://developer.paypal.com/webapps/developer/docs/api/](https://developer.paypal.com/webapps/developer/docs/api/)\n\n## Goals\n\n- [x] Automated tests that don't require manual approval in Paypal account\n- [ ] Automated tests that require manual approval in a Paypal account (with a different build tag, eg. `PAYPAL_APPROVED_PAYMENT_ID`\n- [ ] Concurrency safety by utilizing `PayPal-Request-Id`\n\n## Usage\n\n```bash\ngo get github.com/leebenson/paypal\n```\n\nImport into your app and start using it:\n\n```go\npackage main\n\nimport (\n\t\"fmt\"\n\t\"log\"\n\t\"os\"\n\n\t\"github.com/leebenson/paypal\"\n)\n\nfunc main() {\n\tclientID := os.Getenv(\"PAYPAL_CLIENTID\")\n\tif clientID == \"\" {\n\t\tpanic(\"PayPal clientID is missing\")\n\t}\n\n\tsecret := os.Getenv(\"PAYPAL_SECRET\")\n\tif secret == \"\" {\n\t\tpanic(\"PayPal secret is missing\")\n\t}\n\n\tclient := paypal.NewClient(clientID, secret, paypal.APIBaseLive)\n\n\tpayments, err := client.ListPayments(map[string]string{\n\t\t\"count\":   \"10\",\n\t\t\"sort_by\": \"create_time\",\n\t})\n\tif err != nil {\n\t\tlog.Fatal(\"Could not retrieve payments: \", err)\n\t}\n\n\tfmt.Println(payments)\n}\n```\n\n## Run tests\n\nThis library use [Goconvey](http://goconvey.co/) for tests, so to run them, start Goconvey:\n\n```\nPAYPAL_TEST_CLIENTID=[Paypal Client ID] PAYPAL_TEST_SECRET=[Paypal Secret] goconvey\n```\n\nOr you can just use `go test`\n\n```\nPAYPAL_TEST_CLIENTID=[Paypal Client ID] PAYPAL_TEST_SECRET=[Paypal Secret] go test\n```\n\n## Roadmap\n\n- [x] [Payments - Payment](https://developer.paypal.com/webapps/developer/docs/api/#payments)\n- [x] [Payments - Sale transactions](https://developer.paypal.com/webapps/developer/docs/api/#sale-transactions)\n- [x] [Payments - Refunds](https://developer.paypal.com/webapps/developer/docs/api/#refunds)\n- [x] [Payments - Authorizations](https://developer.paypal.com/webapps/developer/docs/api/#authorizations)\n- [x] [Payments - Captures](https://developer.paypal.com/webapps/developer/docs/api/#billing-plans-and-agreements)\n- [ ] [Payments - Billing Plans and Agreements](https://developer.paypal.com/webapps/developer/docs/api/#billing-plans-and-agreements)\n- [ ] [Payments - Order](https://developer.paypal.com/webapps/developer/docs/api/#orders)\n- [ ] [Vault](https://developer.paypal.com/webapps/developer/docs/api/#vault)\n- [ ] [Identity](https://developer.paypal.com/webapps/developer/docs/api/#identity)\n- [ ] [Invoicing](https://developer.paypal.com/webapps/developer/docs/api/#invoicing)\n- [ ] [Payment Experience](https://developer.paypal.com/webapps/developer/docs/api/#payment-experience)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleebenson%2Fpaypal","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleebenson%2Fpaypal","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleebenson%2Fpaypal/lists"}