|
1 | 1 | # passkit-golang-members-quickstart
|
2 |
| -Quickstart to create, distribute, analyse and manage your Digital Membership for Apple Wallet and Google Pay |
| 2 | + |
| 3 | +__Important Disclaimer:__ _This repository is currently under development. Below instructions are meant as a reference for beta partners, and could be subject to changes. Please note that the environment mentioned in below Quickstart is our Development Environment, which should not be used in a production setting; this is purely for exploratory testing. Data created in our Development Environment can be purged at anytime at our discretion without notice._ |
| 4 | + |
| 5 | +The PassKit IO SDK makes it quick and easy to create and install your branded membership passes for Apple Wallet and Google Pay. |
| 6 | + |
| 7 | + |
| 8 | +This repository has following structure with each purpose. |
| 9 | +- `certs` folder is a place to store your credential files. |
| 10 | +- `examples` folder contains SDK methods you can use to create membership cards and engage with members. |
| 11 | + |
| 12 | +## Table of Content |
| 13 | +* [Installation](#installation) |
| 14 | +* [Prerequisites](#prerequisites) |
| 15 | +* [Quickstart](#quickstart) |
| 16 | +* [Examples](#examples) |
| 17 | +* [GUI Tool](#gui-tool) |
| 18 | +* [Documentation](#documentation) |
| 19 | +* [Check Other Passes](#check-other-passes) |
| 20 | +* [Getting Help](#getting-help) |
| 21 | +* [License](#license) |
| 22 | + |
| 23 | +## Installation |
| 24 | +Install passkit-io-go with: |
| 25 | +```go |
| 26 | +go get -u github.com/PassKit/passkit-golang-sdk |
| 27 | +``` |
| 28 | +Then, import SDK with: |
| 29 | +```go |
| 30 | +import( |
| 31 | + "github.com/PassKit/passkit-golang-sdk/io/members" |
| 32 | + "github.com/PassKit/passkit-golang-sdk/io" |
| 33 | +) |
| 34 | +``` |
| 35 | +## Prerequisites |
| 36 | +1. Create a PassKit account. Sign up for free [HERE](https://dev-app.passkit.io/). |
| 37 | + |
| 38 | +2. Download three `.pem` files you received by email after sign up. |
| 39 | + |
| 40 | + To re-generate credentials, visit Settings (click gear icon in top right of the PassKit.IO web app window) > Developer Credential page and click 'Generate' (Login [HERE](https://dev-app.passkit.io/)). |
| 41 | + |
| 42 | +## Quickstart |
| 43 | +By completing this Quickstart, you will be able to issue a membership card for a new member. |
| 44 | + |
| 45 | +1. Get [prerequisites](#prerequisites) |
| 46 | + |
| 47 | +2. Install passkit-io-go with: |
| 48 | + ```go |
| 49 | + go get -u github.com/PassKit/passkit-golang-sdk |
| 50 | + ``` |
| 51 | + |
| 52 | +3. When you created an account (Prerequisites #1), you should have received 3 files: `certificate.pem`, `key.pem` and `ca-chain.pem` by email. Please save those 3 files under `passkit-golang-members-quickstart/certs` directory. These .pem files are required to authenticate your accesss to PassKit.IO server. |
| 53 | + |
| 54 | +4. Now we need to decrypt your `key.pem`. At your project root directory, run `cd ./certs openssl ec -in key.pem -out key.pem`. Your `key.pem` file should look like below. |
| 55 | +  |
| 56 | + If you do not see `Proc-Type: 4,ENCEYPTED` on line 2, you have successfully decrypted `key.pem`. |
| 57 | + |
| 58 | +5. Replace `[email protected]` in `main.go` with your email address in order to receive the welcome email with card url which your member will also receive. |
| 59 | + |
| 60 | +6. Go back to root directory with `cd ../..`. Then run `go run main.go` to create a sample program (with default template & tier) and issue a membership card against that. |
| 61 | + |
| 62 | +## Examples |
| 63 | +#### Issue A Membership Card. |
| 64 | +Follow 5 steps of [Quickstart](#quickstart) to create a sample membership card and view it on your mobile. |
| 65 | + |
| 66 | +#### Engage With Your Members |
| 67 | +`EngageWithMembers()` contains multiple methods you can use to engage with your members. |
| 68 | +For example, you can update contents of digital membership card or send a push notification. |
| 69 | + |
| 70 | +## GUI Tool |
| 71 | +GUI tool can be accessed from [your PassKit.IO account](https://dev-app.passkit.io/login). |
| 72 | + |
| 73 | +## Documentation |
| 74 | +* [PassKit.IO Membership Official Documentation](https://docs.passkit.io/protocols/member) |
| 75 | + |
| 76 | +## Check Other Passes |
| 77 | +* Coupons (coming soon) |
| 78 | +* Flight Ticket (coming soon) |
| 79 | + |
| 80 | +## Getting Help |
| 81 | + |
| 82 | +* [Online chat support](https://passkit.com/) |
| 83 | + |
| 84 | +## License |
| 85 | +Distributed under MIT License. Details available on [license file](#). |
0 commit comments