{"id":29573241,"url":"https://github.com/auth0-samples/api-quickstarts-tests","last_synced_at":"2025-07-19T05:32:36.790Z","repository":{"id":46701551,"uuid":"137253725","full_name":"auth0-samples/api-quickstarts-tests","owner":"auth0-samples","description":"Test scripts for API Quickstarts","archived":false,"fork":false,"pushed_at":"2023-12-19T14:53:27.000Z","size":15,"stargazers_count":1,"open_issues_count":0,"forks_count":3,"subscribers_count":24,"default_branch":"master","last_synced_at":"2024-04-10T16:07:51.572Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/auth0-samples.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}},"created_at":"2018-06-13T18:13:56.000Z","updated_at":"2021-10-11T19:45:06.000Z","dependencies_parsed_at":"2023-12-19T17:16:59.342Z","dependency_job_id":"d06b3cd3-b834-4fd7-8433-f2065a53c8c1","html_url":"https://github.com/auth0-samples/api-quickstarts-tests","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/auth0-samples/api-quickstarts-tests","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0-samples%2Fapi-quickstarts-tests","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0-samples%2Fapi-quickstarts-tests/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0-samples%2Fapi-quickstarts-tests/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0-samples%2Fapi-quickstarts-tests/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/auth0-samples","download_url":"https://codeload.github.com/auth0-samples/api-quickstarts-tests/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/auth0-samples%2Fapi-quickstarts-tests/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265893947,"owners_count":23845183,"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":[],"created_at":"2025-07-19T05:32:28.222Z","updated_at":"2025-07-19T05:32:36.779Z","avatar_url":"https://github.com/auth0-samples.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# API Quickstart Tests\n\nTests for [API Quickstart samples](https://auth0.com/docs/quickstart/backend).\n\n## Getting Started\n\nClone the repo and install the dependencies.\n\n```bash\nnpm install\n```\n\n## Configure Auth0's API and Clients\n\n[Create an API](https://manage.auth0.com/#/apis), and set the scopes of `read:messages` and `write:messages`.\n\n[Create four clients](https://manage.auth0.com/#/clients) of type **Non Interactive Clients**.\n\nConfigure the following grant between clients and API:\n* A client grant without any scope.\n* A client grant with a scope of `read:messages`.\n* A client grant with a scope of `write:messages`.\n* A client grant with the scopes of `read:messages` and `write:messages`.\n\n## Set up the `.env` file\n\nRename `.env.example` to `.env` and replace the values for variables:\n* `AUTH0_DOMAIN` with your Auth0's domain.\n* `AUTH0_AUDIENCE` with your api identifier configured above.\n* `AUTH0_CLIENT_ID_1` and `AUTH0_CLIENT_SECRET_1` with **client id** and **client secret** from the client without any scope granted.\n* `AUTH0_CLIENT_ID_2` and `AUTH0_CLIENT_SECRET_2` with **client id** and **client secret** from the client with a scope of `read:messages` granted.\n* `AUTH0_CLIENT_ID_3` and `AUTH0_CLIENT_SECRET_3` with **client id** and **client secret** from the client with a scope of `write:messages` granted.\n* `AUTH0_CLIENT_ID_4` and `AUTH0_CLIENT_SECRET_4` with **client id** and **client secret** from the client with the scopes of `read:messages` and `write:messages` granted.\n\n## Running the tests\n\nIn order to run the tests execute:\n\n```bash\nnpm test\n```\n\n**Note:** Returned error codes from the [Symfony](https://auth0.com/docs/quickstart/backend/symfony) API are different from the standard. For those cases execute:\n\n\n```bash\nquickstart=\"symfony\" npm test\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fauth0-samples%2Fapi-quickstarts-tests","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fauth0-samples%2Fapi-quickstarts-tests","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fauth0-samples%2Fapi-quickstarts-tests/lists"}