{"id":47236790,"url":"https://github.com/launchdarkly/gha-flags","last_synced_at":"2026-03-13T23:01:45.386Z","repository":{"id":142302067,"uuid":"503008479","full_name":"launchdarkly/gha-flags","owner":"launchdarkly","description":"Evaluate LaunchDarkly flags in your GitHub Action workflow","archived":false,"fork":false,"pushed_at":"2026-02-24T20:30:13.000Z","size":818,"stargazers_count":5,"open_issues_count":0,"forks_count":2,"subscribers_count":27,"default_branch":"main","last_synced_at":"2026-02-25T00:40:33.302Z","etag":null,"topics":["action","feature-flags","github-action","github-actions","launchdarkly","launchdarkly-integration","managed-by-terraform"],"latest_commit_sha":null,"homepage":"https://docs.launchdarkly.com/integrations/github-actions/flag-evaluations","language":"JavaScript","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/launchdarkly.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2022-06-13T15:16:29.000Z","updated_at":"2026-02-24T20:30:48.000Z","dependencies_parsed_at":null,"dependency_job_id":"d427500e-8059-4030-8bb0-5634e7aa1712","html_url":"https://github.com/launchdarkly/gha-flags","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/launchdarkly/gha-flags","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/launchdarkly%2Fgha-flags","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/launchdarkly%2Fgha-flags/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/launchdarkly%2Fgha-flags/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/launchdarkly%2Fgha-flags/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/launchdarkly","download_url":"https://codeload.github.com/launchdarkly/gha-flags/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/launchdarkly%2Fgha-flags/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30478929,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-13T20:45:58.186Z","status":"ssl_error","status_checked_at":"2026-03-13T20:45:20.133Z","response_time":60,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["action","feature-flags","github-action","github-actions","launchdarkly","launchdarkly-integration","managed-by-terraform"],"created_at":"2026-03-13T23:01:04.535Z","updated_at":"2026-03-13T23:01:45.365Z","avatar_url":"https://github.com/launchdarkly.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LaunchDarkly Flag Evaluation GitHub Action\n\nGitHub Action for evaluating LaunchDarkly flags in your workflow.\n\n\u003c!-- action-docs-inputs --\u003e\n\n## Inputs\n\n| parameter    | description                                                                                                                                     | required | default                         |\n| ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------- | -------- | ------------------------------- |\n| sdk-key      | Server-side SDK key for environment.                                                                                                            | `true`   |                                 |\n| flags        | Provide a list flag keys and default value in a comma separated format with a newline between each flag you want evaluated. `example-flag,true` | `true`   |                                 |\n| context-key  | The key of the context object used in a feature flag evaluation                                                                                 | `false`  | ld-github-action-flags          |\n| send-events  | Whether to send analytics events back to LaunchDarkly                                                                                           | `false`  | true                            |\n| offline      | Whether to use the LaunchDarkly SDK in offline mode                                                                                             | `false`  | false                           |\n| base-uri     | The base URI for the LaunchDarkly server. Most users should use the default value.                                                              | `false`  | https://app.launchdarkly.com    |\n| stream-uri   | The base URI for the LaunchDarkly streaming server. Most users should use the default value.                                                    | `false`  | https://stream.launchdarkly.com |\n| events-uri   | The base URI for the LaunchDarkly events server. Most users should use the default value.                                                       | `false`  | https://events.launchdarkly.com |\n| proxy-auth   | Allows you to specify basic authentication parameters for an optional HTTP proxy. Usually of the form username:password.                        | `false`  |                                 |\n| proxy-host   | Allows you to specify a host for an optional HTTP proxy. Both the host and port must be specified to enable proxy support.                      | `false`  |                                 |\n| proxy-port   | Allows you to specify a port for an optional HTTP proxy. Both the host and port must be specified to enable proxy support.                      | `false`  |                                 |\n| proxy-scheme | When using an HTTP proxy, specifies whether it is accessed via http or https                                                                    | `false`  |                                 |\n\n\u003c!-- action-docs-inputs --\u003e\n\n## Output\n\nThe values of the request flags are stored on the step outputs with the flag key.\n\n**Keys:**\n\nFlag keys used in this GitHub Action must contain only alphanumeric characters, `-`, or `_`.\n\n**Values:**\n\n\u003e Outputs are Unicode strings, and can be a maximum of 1 MB. The total of all outputs in a workflow run can be a maximum of 50 MB.\n\n_Read more: [Metadata syntax](https://docs.github.com/en/actions/creating-actions/metadata-syntax-for-github-actions)_\n\n## Examples\n\n- [Basic](#basic)\n- [Dynamic context key](#dynamic-context-key)\n- [Use value in expression](#use-value-in-expression)\n- [Parse output string to types](#parse-output-string-to-types)\n- [Setting custom contexts](#setting-custom-contexts)\n- [Use with GitHub deployment environments](#use-with-github-deployment-environments)\n- [Disable analytics events](#disable-analytics-events)\n\n### Basic\n\nThis example evaluates flag keys of different types and prints their values.\n\n\u003c!-- x-release-please-start-version --\u003e\n\n```yaml\nname: Evaluate LaunchDarkly flags\non: push\njobs:\n  eval-flags:\n    runs-on: ubuntu-latest\n    steps:\n      - name: Evaluate flags\n        id: flags\n        uses: launchdarkly/gha-flags@v1.0.3\n        with:\n          sdk-key: ${{ secrets.LD_SDK_KEY }}\n          flags: |\n            test-boolean-flag\n            test-string-flag\n            test-number-flag\n            test-json-flag\n      - name: Print flag values\n        run: |\n          echo ${{ steps.flags.outputs.test-boolean-flag }}\n          echo ${{ steps.flags.outputs.test-string-flag }}\n          echo ${{ steps.flags.outputs.test-number-flag }}\n          echo ${{ toJSON(steps.flags.outputs.test-json-flag) }}\n```\n\n\u003c!-- x-release-please-end --\u003e\n\n### Dynamic context key\n\nThis example evaluates a flag for a context. Here, the LaunchDarkly context key is the username of the GitHub user who initiated the workflow run.\n\n_Read more: [GitHub Actions Contexts](https://docs.github.com/en/actions/learn-github-actions/contexts)_\n\n\u003c!-- x-release-please-start-version --\u003e\n\n```yaml\nname: Evaluate LaunchDarkly flags\non: push\njobs:\n  eval-flags:\n    runs-on: ubuntu-latest\n    steps:\n      - name: Evaluate flags\n        id: flags\n        uses: launchdarkly/gha-flags@v1.0.3\n        with:\n          sdk-key: ${{ secrets.LD_SDK_KEY }}\n          flags: favorite-animal\n          context-key: ${{ github.actor }}\n      - name: Favorite animal\n        if: steps.flags.outputs.favorite-animal != 'idk'\n        run: echo \"${{ github.actor }}'s favorite animal is a...${{ steps.flags.outputs.favorite-animal }}\"\n```\n\n\u003c!-- x-release-please-end --\u003e\n\n### Use value in expression\n\nThis example evaluates a flag key and uses the value in an expression in a subsequent step.\n\n\u003c!-- x-release-please-start-version --\u003e\n\n```yaml\nname: Evaluate LaunchDarkly flags\non: push\njobs:\n  eval-flags:\n    runs-on: ubuntu-latest\n    steps:\n      - name: Evaluate flags\n        id: ld\n        uses: launchdarkly/gha-flags@v1.0.3\n        with:\n          sdk-key: ${{ secrets.LD_SDK_KEY }}\n          flags: test-boolean-flag\n      - name: If true\n        if: steps.flags.outputs.test-boolean-flag == 'true'\n        run: echo \"It's true\"\n      - name: If false\n        if: steps.flags.outputs.test-boolean-flag == 'false'\n        run: echo \"It's false\"\n```\n\n\u003c!-- x-release-please-end --\u003e\n\n### Parse output string to types\n\nThis example illustrates how output values are stored as strings. You can parse them to JSON or a JSON data type using [fromJSON()](https://docs.github.com/en/actions/learn-github-actions/expressions#fromjson).\n\n\u003c!-- x-release-please-start-version --\u003e\n\n```yaml\nname: Evaluate LaunchDarkly flags\non: push\njobs:\n  eval-flags:\n    runs-on: ubuntu-latest\n    steps:\n      - name: Evaluate flags\n        id: ld\n        uses: launchdarkly/gha-flags@v1.0.3\n        with:\n          sdk-key: ${{ secrets.LD_SDK_KEY }}\n          flags: test-boolean-flag\n          - name: If true\n            if: fromJSON(steps.flags.outputs.test-boolean-flag) == true\n            run: echo \"It's true\"\n          - name: If false\n            if: fromJSON(steps.flags.outputs.test-boolean-flag) == false\n            run: echo \"It's false\"\n```\n\n\u003c!-- x-release-please-end --\u003e\n\n### Setting custom contexts\n\nIf you would like to include additional custom properties in your context object you may specify environment variables with the `LD_` prefix. All values will be treated at strings.\n\nBy default, all metadata associated with the workflow run is saved in custom properties.\n\n_Read more: [Setting custom contexts](https://docs.launchdarkly.com/home/users/attributes#setting-custom-contexts)_\n\n\u003c!-- x-release-please-start-version --\u003e\n\n```yaml\nname: Evaluate LaunchDarkly flags\non: push\njob:\n  deploy:\n    runs-on: ubuntu-latest\n    steps:\n      - name: Evaluate flags\n        id: ld\n        uses: launchdarkly/gha-flags@v1.0.3\n        with:\n          sdk-key: ${{ secrets.LD_SDK_KEY }}\n          flags: test-boolean-flag\n        env:\n          LD_group: beta\n```\n\n\u003c!-- x-release-please-end --\u003e\n\n### Use with GitHub deployment environments\n\n_Read more: [Using environments for deployment](https://docs.github.com/en/actions/deployment/targeting-different-environments/using-environments-for-deployment)_\n\n\u003c!-- x-release-please-start-version --\u003e\n\n```yaml\nname: Deploy to environment\non: push\njob:\n  deploy:\n    runs-on: ubuntu-latest\n    environment: production\n    steps:\n      - name: Evaluate flags\n        id: ld\n        uses: launchdarkly/gha-flags@v1.0.3\n        with:\n          sdk-key: ${{ secrets.LD_SDK_KEY }} # configure environment-specific secret\n          flags: test-boolean-flag\n```\n\n\u003c!-- x-release-please-end --\u003e\n\n### Disable analytics events\n\nThis example evaluates flag keys without sending events to LaunchDarkly.\n\n_Read more: [Analytics events](https://docs.launchdarkly.com/sdk/concepts/events/)_\n\n\u003c!-- x-release-please-start-version --\u003e\n\n```yaml\nname: Evaluate LaunchDarkly flags\non: push\njobs:\n  eval-flags:\n    runs-on: ubuntu-latest\n    steps:\n      - name: Evaluate flags\n        id: flags\n        uses: launchdarkly/gha-flags@v1.0.3\n        with:\n          sdk-key: ${{ secrets.LD_SDK_KEY }}\n          flags: test-boolean-flag\n          send-events: false\n```\n\n\u003c!-- x-release-please-end --\u003e\n\n## Contributing\n\nWe encourage pull requests and other contributions from the community. Check out our [contributing guidelines](CONTRIBUTING.md) for instructions on how to contribute to this project.\n\n## About LaunchDarkly\n\n- LaunchDarkly is a continuous delivery platform that provides feature flags as a service and allows developers to iterate quickly and safely. We allow you to easily flag your features and manage them from the LaunchDarkly dashboard. With LaunchDarkly, you can:\n  - Roll out a new feature to a subset of your users (like a group of users who opt-in to a beta tester group), gathering feedback and bug reports from real-world use cases.\n  - Gradually roll out a feature to an increasing percentage of users, and track the effect that the feature has on key metrics (for instance, how likely is a user to complete a purchase if they have feature A versus feature B?).\n  - Turn off a feature that you realize is causing performance problems in production, without needing to re-deploy, or even restart the application with a changed configuration file.\n  - Grant access to certain features based on user attributes, like payment plan (eg: users on the ‘gold’ plan get access to more features than users in the ‘silver’ plan). Disable parts of your application to facilitate maintenance, without taking everything offline.\n- LaunchDarkly provides feature flag SDKs for a wide variety of languages and technologies. Check out [our documentation](https://docs.launchdarkly.com/sdk) for a complete list.\n- Explore LaunchDarkly\n  - [launchdarkly.com](https://www.launchdarkly.com/ 'LaunchDarkly Main Website') for more information\n  - [docs.launchdarkly.com](https://docs.launchdarkly.com/ 'LaunchDarkly Documentation') for our documentation and SDK reference guides\n  - [apidocs.launchdarkly.com](https://apidocs.launchdarkly.com/ 'LaunchDarkly API Documentation') for our API documentation\n  - [blog.launchdarkly.com](https://blog.launchdarkly.com/ 'LaunchDarkly Blog Documentation') for the latest product updates\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flaunchdarkly%2Fgha-flags","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flaunchdarkly%2Fgha-flags","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flaunchdarkly%2Fgha-flags/lists"}