Skip to content
This repository has been archived by the owner on Jun 16, 2023. It is now read-only.
/ go-copilot Public archive

An unofficial SDK for the Copilot.cx server API

License

Notifications You must be signed in to change notification settings

GetWagz/go-copilot

Repository files navigation

Copilot.cx Go SDK

Go Report Card GitHub license Maintenance

This library is a wrapper around the Copilot.cx collect API.

Deprecation and Maintenance

Unfortunately, this repository is no longer being maintained. If you would like to take over maintenance of the repository, please open up an issue in this repository or otherwise contact us. We apologize if this is an inconvenience at all. We are going to freeze this archive. Feel free to fork it as you desire. Best of luck!

Usage

Usage is fairly straight-forward. The init function will read from the environment to try to configure the client. However, in some cases you may want to initialize the client programatically, so you may also call the Setup function directly.

Environment Variables

  • COPILOT_CLIENT_ID The client id for your Copilot instance
  • COPILOT_CLIENT_SECRET The secret key for your instance
  • COPILOT_CLIENT_COLLECT_ENDPOINT The collect endpoint
  • COPILOT_CLIENT_CONSENT_ENDPOINT The consent endpoint, needed for GDPR systems

Testing

Testing requires an actual account. We can do some initial error checking without credentials, but full testing requires the credentials of an instance to use. Copilot currently does not offer a way to completely remove and reset data so testing may appear minimal without credentials. This library is used in production.

Other Libraries

We use the following additional tools in this library, and thank the maintainers and contributors of those libraries:

  • testify - Makes our unit tests more readable and management

Known Issues

  • Testing needs to be expanded, ideally with an ability to use a testing sandbox or the ability to reset an environment

Hiring

Are you interested in working on improving pet lives through innovative technologies and love Go, Typescript, Swift, or Java? Send an email to engineering@wagz.comand let's find out if we're a good match!

Contributing

Pull Requests are welcome! See our CONTRIBUTING.md file for more information.