{"id":16123691,"url":"https://github.com/austenstone/json-to-csv","last_synced_at":"2026-01-15T23:53:06.239Z","repository":{"id":220171379,"uuid":"750901443","full_name":"austenstone/json-to-csv","owner":"austenstone","description":"GitHub Action to Convert JSON to CSV","archived":false,"fork":false,"pushed_at":"2024-04-29T06:44:58.000Z","size":4471,"stargazers_count":0,"open_issues_count":5,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-08T01:27:19.434Z","etag":null,"topics":["actions","csv","json"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/austenstone.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":["austenstone"]}},"created_at":"2024-01-31T14:50:38.000Z","updated_at":"2024-01-31T19:56:50.000Z","dependencies_parsed_at":"2024-04-29T07:55:38.125Z","dependency_job_id":null,"html_url":"https://github.com/austenstone/json-to-csv","commit_stats":null,"previous_names":["austenstone/json-to-csv"],"tags_count":3,"template":false,"template_full_name":"austenstone/action-typescript","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/austenstone%2Fjson-to-csv","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/austenstone%2Fjson-to-csv/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/austenstone%2Fjson-to-csv/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/austenstone%2Fjson-to-csv/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/austenstone","download_url":"https://codeload.github.com/austenstone/json-to-csv/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246794205,"owners_count":20834938,"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":["actions","csv","json"],"created_at":"2024-10-09T21:18:20.363Z","updated_at":"2026-01-15T23:53:06.210Z","avatar_url":"https://github.com/austenstone.png","language":"TypeScript","funding_links":["https://github.com/sponsors/austenstone"],"categories":[],"sub_categories":[],"readme":"# JSON to CSV Action\n\nThis action converts a JSON string to a CSV string.\n\n## Usage\nCreate a workflow (eg: `.github/workflows/csv.yml`). See [Creating a Workflow file](https://help.github.com/en/articles/configuring-a-workflow#creating-a-workflow-file).\n\n\u003c!-- \n### PAT(Personal Access Token)\n\nYou will need to [create a PAT(Personal Access Token)](https://github.com/settings/tokens/new?scopes=admin:org) that has `admin:org` access.\n\nAdd this PAT as a secret so we can use it as input `github-token`, see [Creating encrypted secrets for a repository](https://docs.github.com/en/enterprise-cloud@latest/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-a-repository). \n### Organizations\n\nIf your organization has SAML enabled you must authorize the PAT, see [Authorizing a personal access token for use with SAML single sign-on](https://docs.github.com/en/enterprise-cloud@latest/authentication/authenticating-with-saml-single-sign-on/authorizing-a-personal-access-token-for-use-with-saml-single-sign-on).\n--\u003e\n\u003e [!NOTE]  \n\u003e The output of this action might exceed the maximum size of inputs/outputs. In that case leverage the generated artifacts.\n\n#### Basic Usage\n\n```yml\nname: JSON to CSV\non:\n  workflow_dispatch:\n\njobs:\n  run:\n    name: Run Action\n    runs-on: ubuntu-latest\n    steps:\n      - uses: austenstone/json-to-csv@main\n        id: csv\n        with:\n          json: '[{\"name\":\"John\",\"age\":30,\"city\":\"New York\"},{\"name\":\"Jane\",\"age\":25,\"city\":\"New York\"}]'\n      - run: echo \"${{ steps.csv.outputs.csv }}\"\n```\n#### Output Artifact\nYou can output an artifact instead of a string. Use `artifact-name` to specify the name of the artifact.\n\n```yml\n    steps:\n      - uses: austenstone/json-to-csv@main\n        with:\n          json: '[{\"name\":\"John\",\"age\":30,\"city\":\"New York\"},{\"name\":\"Jane\",\"age\":25,\"city\":\"New York\"}]'\n          create-artifact: true\n      - uses: actions/download-artifact@v4\n        with:\n          name: ${{ steps.export.outputs.artifact-name }}\n```\n\n#### Input Artifact\nYou can pass an artifact name to the action and it will use the JSON file/s in the artifact as input.\n\n```yml\n    steps:\n      - uses: austenstone/json-to-csv@main\n        with:\n          json-artifact-name: ${{ steps.export.outputs.artifact-name }}\n```\n\n## ➡️ Inputs\nVarious inputs are defined in [`action.yml`](action.yml):\n\n| Name | Description | Default |\n| --- | - | - |\n| json | The JSON to convert to CSV. | N/A |\n| json-artifact-name | The name of the artifact to use as input instead of `json`. | N/A |\n| options | A JSON string of options https://www.npmjs.com/package/json-2-csv#json2csvarray-options--string | N/A |\n| create-artifact | Whether to create an artifact with the output. | false |\n| artifact-name | The name of the artifact to create. | json-to-csv |\n\n## ⬅️ Outputs\n| Name | Description |\n| --- | - |\n| csv | The csv output. |\n| artifact-name | The name of the artifact created. |\n\n\n## Further help\nTo get more help on the Actions see [documentation](https://docs.github.com/en/actions).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faustenstone%2Fjson-to-csv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faustenstone%2Fjson-to-csv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faustenstone%2Fjson-to-csv/lists"}