{"id":23331116,"url":"https://github.com/sassoftware/event-provenance-registry","last_synced_at":"2025-04-09T16:10:21.653Z","repository":{"id":208099293,"uuid":"719610874","full_name":"sassoftware/event-provenance-registry","owner":"sassoftware","description":"The Event Provenance Registry (EPR) is a service that manages and stores events and tracks event-receivers and event-receiver-groups.","archived":false,"fork":false,"pushed_at":"2024-11-08T21:03:44.000Z","size":427,"stargazers_count":6,"open_issues_count":20,"forks_count":4,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-03-23T18:22:39.203Z","etag":null,"topics":["cdevents","cdfoundation","event-driven"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sassoftware.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":"SUPPORT.md","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-11-16T14:32:15.000Z","updated_at":"2024-11-08T21:03:46.000Z","dependencies_parsed_at":"2024-01-19T22:25:29.037Z","dependency_job_id":"386a88d5-348d-460d-8665-67611760d269","html_url":"https://github.com/sassoftware/event-provenance-registry","commit_stats":null,"previous_names":["sassoftware/event-provenance-registry"],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sassoftware%2Fevent-provenance-registry","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sassoftware%2Fevent-provenance-registry/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sassoftware%2Fevent-provenance-registry/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sassoftware%2Fevent-provenance-registry/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sassoftware","download_url":"https://codeload.github.com/sassoftware/event-provenance-registry/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248065283,"owners_count":21041871,"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":["cdevents","cdfoundation","event-driven"],"created_at":"2024-12-20T22:31:07.938Z","updated_at":"2025-04-09T16:10:21.633Z","avatar_url":"https://github.com/sassoftware.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Event Provenance Registry (EPR)\n\n## Overview\n\nEvent Provenance Registry (EPR) is a provenance store. It keeps track of events.\nWith EPR, you can use the API to create, retrieve, and query events, event\nreceivers, and groups of event receivers.\n\n## Description\n\nThe Event Provenance Registry (EPR) is a service that stores events and tracks\nevent-receivers and event-receiver-groups. EPR provides an API that lets you\ncreate events, event-receivers, and event-receiver-groups. You can query the EPR\nusing the GraphQL endpoint to get identifying information about events,\nevent-receivers, and event-receiver-groups. EPR collects events from the supply\nchain to record the lifecycle of a unit in the SDLC. EPR validates\nevent-receivers have events. EPR emits a message when a event is received as\nwell as when an event-receiver-groups is complete for a unit version.\n\n[EPR Documentation](./docs/README.md)\n\n## Develop\n\n### Build\n\n```bash\nmake\n```\n\n## Installation\n\nTo install in `/usr/local/bin` directory\n\nLinux\n\n```bash\nmake install\n```\n\nMac OS X\n\n```bash\nmake install-darwin\n```\n\nTo install in your go path directory set `PREFIX`\n\nLinux\n\n```bash\nmake PREFIX=$(go env GOPATH) install\n```\n\nMac OS X\n\n```bash\nmake PREFIX=$(go env GOPATH) install-darwin\n```\n\n## Tests\n\nRun the go unit tests:\n\n```bash\nmake test\n```\n\n## Linter\n\nRun golangci-lint (requires\n[golangci-lint](https://golangci-lint.run/usage/install/)):\n\n```bash\nmake megalint\n```\n\n## Usage\n\n```txt\nUsage:\n  epr-server [flags]\n\nFlags:\n      --brokers string   broker uris separated by commas (default \"localhost:9092\")\n      --config string    config file (default is $XDG_CONFIG_HOME/epr/epr.yaml)\n      --db string        database connection string (default \"postgres://localhost:5432\")\n      --debug            Enable debugging statements\n  -h, --help             help for epr-server\n      --host string      host to listen on (default \"localhost\")\n      --port string      port to listen on (default \"8042\")\n      --topic string     topic to produce events on (default \"epr.dev.events\")\n```\n\n### Running the Server\n\nSee [the docs](docs/how-to/start-server/README.md) for how to start EPR and its\ndependencies.\n\n### Interacting with the Server\n\nAn event receiver is an object that represents some type of action that would\noccur in your pipeline (i.e. a build, a test run, a deployment, etc...).\n\nCreate an event receiver:\n\n```bash\ncurl --location --request POST 'http://localhost:8042/api/v1/receivers' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n  \"name\": \"foobar\",\n  \"type\": \"whatever\",\n  \"version\": \"1.1.2\",\n  \"description\": \"it does stuff\",\n  \"enabled\": true,\n  \"schema\": {\n  \"type\": \"object\",\n  \"properties\": {\n    \"name\": {\n      \"type\": \"string\"\n    }\n  }\n}\n}'\n```\n\nWhen you create an event, you must specify an `event_receiver_id` to associate\nit with. An event is the record of some action being completed. You cannot\ncreate an event for a non-existent receiver ID. The payload field of the event\nmust conform to the schema defined on the event receiver that you have given the\nID of.\n\nCreate an event:\n\n```bash\ncurl --location --request POST 'http://localhost:8042/api/v1/events' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n    \"name\": \"idc\",\n    \"version\": \"2.2.2\",\n    \"release\": \"whatever\",\n    \"platform_id\": \"linux\",\n    \"package\": \"docker\",\n    \"description\": \"blah\",\n    \"payload\": {\"name\":\"bob\"},\n    \"success\": true,\n    \"event_receiver_id\": \"01HDS785T0V8KTSTDM9XGT33QQ\"\n}'\n```\n\nCreate a group:\n\n```bash\ncurl --location --request POST 'http://localhost:8042/api/v1/groups' \\\n--header 'Content-Type: application/json' \\\n--data-raw '{\n    \"name\": \"group\",\n    \"type\": \"notyours\",\n    \"version\": \"3.3.3\",\n    \"description\": \"foobar\",\n    \"enabled\": true,\n    \"event_receiver_ids\": [\"01H9GW7FYY4XYE2R930YTFM7FM\"]\n}'\n```\n\n## GraphQL\n\nCurl commands for GraphQL Search\n\n```bash\ncurl -X POST -H \"content-type:application/json\" -d '{\"query\":\"query FindEvents($id: ID!){events(id: $id) {id,name,version,release,platform_id,package,description,payload,success,created_at,event_receiver_id}}\",\"variables\":{\"id\":\"01HKX1TMQZQDS6NC5DG7WNXXCJ\"}}' http://localhost:8042/api/v1/graphql/query\n```\n\n```bash\ncurl -X POST -H \"content-type:application/json\" -d '{\"query\":\"query FindEventReceivers($id: ID!){event_receivers(id: $id) {id,name,version,description,type,schema,created_at}}\",\"variables\":{\"id\":\"01HKX0KY3B31MR3XKJWTDZ4EQ0\"}}' http://localhost:8042/api/v1/graphql/query\n```\n\n```bash\ncurl -X POST -H \"content-type:application/json\" -d '{\"query\":\"query FindEventReceiverGroups($id: ID!){event_receiver_groups(id: $id) {id,name,type,version,description,enabled,event_receiver_ids,created_at,updated_at}}\",\"variables\":{\"id\":\"01HKX90FKWQZ49F6H5V5NQT95Z\"}}' http://localhost:8042/api/v1/graphql/query\n```\n\n## Links\n\n- [EPR Python Client](https://github.com/xbcsmith/epr-python)\n- [EPR Workshop](https://github.com/xbcsmith/epr-workshop)\n\n## Contributing\n\nWe welcome your contributions! Please read [CONTRIBUTING.md](CONTRIBUTING.md)\nfor details on how to submit contributions to this project.\n\n## License\n\nThis project is licensed under the [Apache 2.0 License](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsassoftware%2Fevent-provenance-registry","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsassoftware%2Fevent-provenance-registry","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsassoftware%2Fevent-provenance-registry/lists"}