{"id":24678317,"url":"https://github.com/firstclasspostcodes/firstclasspostcodes-mock","last_synced_at":"2025-03-21T18:23:32.154Z","repository":{"id":54787566,"uuid":"193097378","full_name":"firstclasspostcodes/firstclasspostcodes-mock","owner":"firstclasspostcodes","description":"🔀 Provides a mock HTTP server that responds like the real Firstclasspostcodes API to make test suites integrating with us faster and less brittle.","archived":false,"fork":false,"pushed_at":"2021-01-29T08:15:37.000Z","size":1471,"stargazers_count":1,"open_issues_count":12,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-26T13:16:37.117Z","etag":null,"topics":["docker","firstclasspostcodes","nodejs"],"latest_commit_sha":null,"homepage":"","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/firstclasspostcodes.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}},"created_at":"2019-06-21T12:51:21.000Z","updated_at":"2021-01-04T10:43:29.000Z","dependencies_parsed_at":"2022-08-14T03:00:32.399Z","dependency_job_id":null,"html_url":"https://github.com/firstclasspostcodes/firstclasspostcodes-mock","commit_stats":null,"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstclasspostcodes%2Ffirstclasspostcodes-mock","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstclasspostcodes%2Ffirstclasspostcodes-mock/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstclasspostcodes%2Ffirstclasspostcodes-mock/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firstclasspostcodes%2Ffirstclasspostcodes-mock/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/firstclasspostcodes","download_url":"https://codeload.github.com/firstclasspostcodes/firstclasspostcodes-mock/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244845403,"owners_count":20519954,"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":["docker","firstclasspostcodes","nodejs"],"created_at":"2025-01-26T13:16:38.789Z","updated_at":"2025-03-21T18:23:32.127Z","avatar_url":"https://github.com/firstclasspostcodes.png","language":"JavaScript","readme":"# 🔀 API Mock\n\n![Build, test and release](https://github.com/firstclasspostcodes/firstclasspostcodes-mock/workflows/Build,%20test%20and%20release/badge.svg)\n\nA HTTP mock server that responds like the real Firstclasspostcodes API. It is intended for use by clients integrating with our API, in order to improve integration testing and to ensure tests are less brittle.\n\nTo get started using the API, [read the docs](https://docs.firstclasspostcodes.com).\n\nWe provide clients in [Ruby](https://github.com/firstclasspostcodes/firstclasspostcodes-ruby), [PHP](https://github.com/firstclasspostcodes/firstclasspostcodes-php), [Javascript/NodeJS](https://github.com/firstclasspostcodes/firstclasspostcodes-js), [Python](https://github.com/firstclasspostcodes/firstclasspostcodes-python). To configure the client libraries to connect to this mock API, view the relevant library documentation.\n\n## Usage\n\nA docker container is provided for ease of use:\n\n```sh\ndocker run -p 80:2345 firstclasspostcodes/mock:v4.0.5.\n```\n\nNow start calling the Firstclasspostcodes API:\n\n```\ncurl -H 'X-Api-Key:111111111111' http://localhost:2345/postcode?search=AR514UI\n```\n\n### API Key\n\nThe API Key is **always** `111111111111`. If an API Key is not provided, `403` response is returned. \n\n## Data\n\nA small set of test data is available for querying through the mock API. A special endpoint is provided `GET: /data/.postcodes` which will list all postcodes currently provided for testing purposes.\n\nWhilst the test data is sourced from our live API, it may not be in sync with updates.\n\n\u003e Note: Additional postcodes will be added in **major releases**.\n\n## Local Development\n\nThis is a node project, so first run `npm i` to fetch all the project dependencies. You'll also need a local version of the OpenAPI specification file to work with:\n\n```\ncurl -o spec.json https://api.firstclasspostcodes.com/data/.spec\n```\n\nRunning `npm start` will boot up the server. ","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirstclasspostcodes%2Ffirstclasspostcodes-mock","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffirstclasspostcodes%2Ffirstclasspostcodes-mock","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirstclasspostcodes%2Ffirstclasspostcodes-mock/lists"}