{"id":17023965,"url":"https://github.com/devside/dynamock","last_synced_at":"2025-09-21T12:17:25.212Z","repository":{"id":35555018,"uuid":"196619385","full_name":"DevSide/dynamock","owner":"DevSide","description":"Dynamic mock server which serves fixtures based on request's property matching","archived":false,"fork":false,"pushed_at":"2025-08-21T16:22:35.000Z","size":3171,"stargazers_count":2,"open_issues_count":6,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-09-13T04:39:33.560Z","etag":null,"topics":["dynamic","fixtures","mock","server"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DevSide.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"zenodo":null}},"created_at":"2019-07-12T17:30:33.000Z","updated_at":"2025-04-10T13:42:09.000Z","dependencies_parsed_at":"2024-11-10T15:35:01.064Z","dependency_job_id":"4285c536-265a-486c-b724-c842bb065044","html_url":"https://github.com/DevSide/dynamock","commit_stats":{"total_commits":119,"total_committers":8,"mean_commits":14.875,"dds":0.4957983193277311,"last_synced_commit":"0ecfc38c999aff5d2272ddd00dfee92df15144b3"},"previous_names":[],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/DevSide/dynamock","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevSide%2Fdynamock","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevSide%2Fdynamock/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevSide%2Fdynamock/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevSide%2Fdynamock/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DevSide","download_url":"https://codeload.github.com/DevSide/dynamock/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DevSide%2Fdynamock/sbom","scorecard":{"id":39829,"data":{"date":"2025-08-11","repo":{"name":"github.com/DevSide/dynamock","commit":"e491401f8671e9f9ca083bb016b7c261deffba9d"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.2,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/27 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/ci.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:11: update your workflow using https://app.stepsecurity.io/secureworkflow/DevSide/dynamock/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/DevSide/dynamock/ci.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/ci.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/DevSide/dynamock/ci.yml/master?enable=pin","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 third-party GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":0,"reason":"license file not detected","details":["Warn: project does not have a license file"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 23 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"11 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-x4c5-c7rf-jjgv","Warn: Project is vulnerable to: GHSA-h5c3-5r3r-rr8q","Warn: Project is vulnerable to: GHSA-rmvr-2pp2-xj38","Warn: Project is vulnerable to: GHSA-xx4v-prfh-6cgc","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-h7cp-r72f-jxh6","Warn: Project is vulnerable to: GHSA-v62p-rq8g-8h59","Warn: Project is vulnerable to: GHSA-8cj5-5rvv-wf4v"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-14T21:13:20.317Z","repository_id":35555018,"created_at":"2025-08-14T21:13:20.317Z","updated_at":"2025-08-14T21:13:20.317Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276238755,"owners_count":25608475,"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","status":"online","status_checked_at":"2025-09-21T02:00:07.055Z","response_time":72,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["dynamic","fixtures","mock","server"],"created_at":"2024-10-14T07:14:54.876Z","updated_at":"2025-09-21T12:17:25.155Z","avatar_url":"https://github.com/DevSide.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# dynamock\n\n[![npm version](https://img.shields.io/npm/v/dynamock)](https://www.npmjs.com/package/dynamock)\n![node](https://img.shields.io/node/v/dynamock)\n[![Build Status](https://github.com/devside/dynamock/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/DevSide/dynamock/actions/workflows/ci.yml?query=branch%3Amaster)\n[![Coverage Status](https://coveralls.io/repos/github/DevSide/dynamock/badge.svg?branch=master)](https://coveralls.io/github/DevSide/dynamock?branch=master)\n\n`dynamock` is a dynamic mock/fixture HTTP server designed for functional testing.\u003cbr\u003e\n\n## Installation\n\n```bash\nyarn add dynamock -D\n# or NPM\nnpm install dynamock --save-dev\n```\n\n## Usage\n\n### ⚠️ Security\n\nBe aware of running your dynamock server in a CLOSED network, there is no authentication required to configure it.\u003cbr\u003e\nIt is highly recommended using dynamock for dev/testing purpose ONLY.\n\n### Run the server (NodeJS required)\n\n```bash\n# dynamock PORT [HOST]\ndynamock 3001\n```\n\n### Inject fixtures\n\n```js\nfetch('http://localhost:3001/___fixtures', {\n  method: 'POST',\n  headers: {\n    'Content-Type': 'application/json',\n  },\n  body: JSON.stringify({\n    request: {\n      method: 'GET',\n      path: '/products/1'\n    },\n    response: {\n      body: {\n        id: 1\n      }\n    }\n  })\n})\n```\n\n### Consume fixtures\n\n```js\nfetch('http://localhost:3001/products/1', { method: 'GET' })\n  .then(response =\u003e response.json())\n  .then(response =\u003e assert.equal(response, { id: 1 }))\n```\n\nDynamock is designed to remove the fixture once consumed, see options.lifetime to adapt this behavior.\n\n```js\nfetch('http://localhost:3001/products/1', { method: 'GET' }).then(response =\u003e assert.equal(response.status, 404))\n```\n\n## Property response matching\n\nBy default, dynamock uses partial matching for `headers`, `query` and `cookies`.\n\n## Configuration api\n\nUsing the configuration is optional. However, it gives the ability of reusing redundant data across requests and simplifying fixtures setup.\n\n### \u003cimg src=\"https://img.shields.io/badge/GET-61affe.svg\" alt=\"GET\" /\u003e /\\_\\_\\_config - **Retrieve configuration**\n\n**Responses**\n\n- Status 200 - OK\n\n```json\n{\n  \"cors\": \"{null|'*'} - '*' allows all requests via cors headers, this creates a global route OPTIONS\",\n  \"headers\": \"{object} - Dictionary of headers (object) by name (string)\",\n  \"query\": \"{object} - Dictionary of query (object) by name (string)\",\n  \"cookies\": \"{object} - Dictionary of cookies (object) by name (string)\"\n}\n```\n\nExample:\n\n```json\n{\n  \"cors\": null,\n  \"headers\": {},\n  \"query\": {},\n  \"cookies\": {}\n}\n```\n\n### \u003cimg src=\"https://img.shields.io/badge/PUT-fca130.svg\" alt=\"PUT\" /\u003e /\\_\\_\\_config - **Update configuration**\n\n**Request**\n\n- Body\n\n```json\n{\n  \"cors\": \"{null|'*'} [default=null] - '*' allows all requests via cors headers, this creates a global route OPTIONS\",\n  \"headers\": \"{object} [default={}] - Dictionary of headers (object) by name (string)\",\n  \"query\": \"{object} [default={}] - Dictionary of query (object) by name (string)\",\n  \"cookies\": \"{object} [default={}] - Dictionary of cookies (object) by name (string)\"\n}\n```\n\nExample:\n\n```json\n{\n  \"cors\": \"*\",\n  \"headers\": {\n    \"apiBearer\": {\n      \"Authorization\": \"Bearer xyz\"\n    }\n  }\n}\n```\n\n**Responses**\n\n- Status 200 - OK\n\n```json\n{\n  \"cors\": \"{null|'*'}\",\n  \"headers\": \"{object}\",\n  \"query\": \"{object}\",\n  \"cookies\": \"{object}\"\n}\n```\n\nExample:\n\n```json\n{\n  \"cors\": null,\n  \"headers\": {\n    \"captcha\": {\n      \"X-CAPTCHA-TOKEN\": \"fake\"\n    },\n    \"cors\": {\n      \"Access-Control-Allow-Origin\": \"*\",\n      \"Access-Control-Allow-Methods\": \"*\",\n      \"Access-Control-Allow-Headers\": \"*\"\n    }\n  },\n  \"query\": {\n    \"campaign\": {\n      \"utm_source\": \"x\",\n      \"utm_campaign\": \"y\"\n    }\n  },\n  \"cookies\": {\n    \"anonymousUser\": {\n      \"PHPSESSID\": \"x\"\n    },\n    \"loggedInUser\": {\n      \"PHPSESSID\": \"y\"\n    }\n  }\n}\n```\n\n- Status 400 - BAD REQUEST\n\n```\nWrong configuration format\n```\n\n\u003cbr/\u003e\n\n### \u003cimg src=\"https://img.shields.io/badge/DELETE-f93e3e.svg\" alt=\"DELETE\" /\u003e /\\_\\_\\_config - **Reset configuration**\n\n**Responses**\n\n- Status 204 - NO CONTENT\n\n\u003cbr\u003e\n\n## Fixtures api\n\nA fixture is composed of:\n\n- request data to match the incoming requests\n- response data to define the result(s) of the requests\n\n\u003cbr/\u003e\n\n### \u003cimg src=\"https://img.shields.io/badge/POST-49cc90.svg\" alt=\"POST\" /\u003e /\\_\\_\\_fixtures - **Add fixture**\n\n**Request**\n\n- Body\n\n```json\n{\n  \"request\": {\n    \"method\": \"{string} - Http method to match requests, case insensitive, use wildcard '*' to match all\",\n    \"path\": \"{string} - Http path to match requests, use wildcard '*' to match all\",\n    \"headers\": \"{object|array} [default={}] - Headers to match requests\",\n    \"query\": \"{object|array} [default={}] - Query to match requests\",\n    \"cookies\": \"{object|array} [default={}] - Cookies to match requests\",\n    \"body\": \"{object} [default=``] - Body to match requests\",\n    \"options\": {\n      \"path\": {\n        \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\",\n        \"disableEncodeURI\": \"{boolean} [default=false] - Disable encode URI, always on when allowRegex is true\"\n      },\n      \"method\": {\n        \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n      },\n      \"headers\": {\n        \"strict\": \"{boolean} [default=false] - Strictly match headers\",\n        \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n      },\n      \"cookies\": {\n        \"strict\": \"{boolean} [default=false] - Strictly match cookies\",\n        \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n      },\n      \"query\": {\n        \"strict\": \"{boolean} [default=false] - Strictly match query\",\n        \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n      },\n      \"body\": {\n        \"strict\": \"{boolean} [default=false] - Strictly match body\",\n        \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n      }\n    }\n  },\n  \"response\": {\n    \"status\": \"{number} [default=200] - Response status code\",\n    \"headers\": \"{object|array} [default={}] - Response headers\",\n    \"cookies\": \"{object|array} [default={}] - Response cookies\",\n    \"body\": \"{string|object|array} [default=``] - Body to response\",\n    \"filepath\": \"{string} [default=``] - Absolute filepath to serve with auto mime-types\",\n    \"options\": {\n      \"delay\": \"{number} [default=0] - Delay the response with a number of milliseconds\",\n      \"lifetime\": \"{number} [default=1] - Number of times the fixture can be consumed before getting removed, use 0 for unlimited consumption\"\n    }\n  },\n  \"responses\": \"{array} [default=[]] - Array of responses\"\n}\n```\n\nExamples:\n\n```json\n{\n  \"request\": {\n    \"method\": \"GET\",\n    \"path\": \"/pandas\"\n  },\n  \"response\": {\n    \"body\": [{ \"id\": \"1\" }, { \"id\": \"2\" }]\n  }\n}\n```\n\n```json\n{\n  \"request\": {\n    \"method\": \"GET\",\n    \"path\": \"/cdn/images/fennec.jpg\"\n  },\n  \"response\": {\n    \"filepath\": \"/absolute/path/tofennec.jpg\",\n    \"options\": {\n      \"delay\": 1000\n    }\n  }\n}\n```\n\n```json\n{\n  \"request\": {\n    \"method\": \"POST\",\n    \"path\": \"/heros\",\n    \"body\": {\n      \"name\": \"po\",\n      \"type\": \"panda\"\n    },\n    \"options\": {\n      \"body\": {\n        \"strict\": true\n      }\n    }\n  },\n  \"response\": {\n    \"body\": {\n      \"id\": \"1\",\n      \"name\": \"po\",\n      \"type\": \"panda\"\n    }\n  }\n}\n```\n\n```json\n{\n  \"request\": {\n    \"method\": \"OPTIONS\",\n    \"path\": \"*\"\n  },\n  \"response\": {\n    \"headers\": {\n      \"Access-Control-Allow-Origin\": \"*\",\n      \"Access-Control-Allow-Methods\": \"*\",\n      \"Access-Control-Allow-Headers\": \"*\"\n    },\n    \"body\": \"\"\n  }\n}\n```\n\n```json\n{\n  \"request\": {\n    \"method\": \"get\",\n    \"path\": \"/\"\n  },\n  \"responses\": [\n    {\n      \"body\": \"first return\"\n    },\n    {\n      \"body\": \"second return\"\n    }\n  ]\n}\n```\n\n```json\n{\n  \"request\": {\n    \"method\": \"GET\",\n    \"path\": \"/\",\n    \"headers\": {\n      \"user-agent\": \"/firefox/70$/i\"\n    },\n    \"options\": {\n      \"headers\": {\n        \"allowRegex\": true\n      }\n    }\n  },\n  \"response\": {\n    \"body\": \"Only for Firefox 70 users !\"\n  }\n}\n```\n\n```json\n{\n  \"request\": {\n    \"method\": \"GET\",\n    \"path\": \"/%20a\",\n    \"options\": {\n      \"path\": {\n        \"disableEncodeURI\": true\n      }\n    }\n  },\n  \"response\": {\n    \"body\": \"This will match '/ a' or '/%20a' calls\"\n  }\n}\n```\n\n\n**Responses**\n\n- Status 200 - OK\n\n```json\n{\n  \"id\": \"{string}\"\n}\n```\n\nExample:\n\n```json\n{\n  \"id\": \"38ed32e9fb0a1e5c7cb1b6f0ff43f6060d8b4508\"\n}\n```\n\n- Status 400 - BAD REQUEST\n\nThe configuration is not valid\n\n- Status 409 - CONFLICT\n\n```\nRoute {METHOD} ${PATH} is already registered.\n```\n\n\u003cbr/\u003e\n\n### \u003cimg src=\"https://img.shields.io/badge/POST-49cc90.svg\" alt=\"POST\" /\u003e /\\_\\_\\_fixtures/bulk - **Bulk add fixtures**\n\nIt is meant to setup multiple fixtures at once.\n\n**Request**\n\n- Body\n\n```json\n[\n  {\n    \"request\": {\n      \"method\": \"{string} - Http method to match requests, case insensitive, use wildcard '*' to match all\",\n      \"path\": \"{string} - Http path to match requests, use wildcard '*' to match all\",\n      \"headers\": \"{object|array} [default={}] - Headers to match requests\",\n      \"query\": \"{object|array} [default={}] - Query to match requests\",\n      \"cookies\": \"{object|array} [default={}] - Cookies to match requests\",\n      \"body\": \"{object} [default=``] - Body to match requests\",\n      \"options\": {\n        \"path\": {\n          \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n        },\n        \"method\": {\n          \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n        },\n        \"headers\": {\n          \"strict\": \"{boolean} [default=false] - Strictly match headers\",\n          \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n        },\n        \"cookies\": {\n          \"strict\": \"{boolean} [default=false] - Strictly match cookies\",\n          \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n        },\n        \"query\": {\n          \"strict\": \"{boolean} [default=false] - Strictly match query\",\n          \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n        },\n        \"body\": {\n          \"strict\": \"{boolean} [default=false] - Strictly match body\",\n          \"allowRegex\": \"{boolean} [default=false] - Allow matching RegExp\"\n        }\n      }\n    },\n    \"response\": {\n      \"status\": \"{number} [default=200] - Response status code\",\n      \"headers\": \"{object|array} [default={}] - Response headers\",\n      \"cookies\": \"{object|array} [default={}] - Response cookies\",\n      \"body\": \"{string|object|array} [default=``] - Body response\",\n      \"filepath\": \"{string} [default=``] - Absolute filepath to serve with auto mime-types\",\n      \"options\": {\n        \"delay\": \"{number} [default=0] - Delay the response with a number of milliseconds\",\n        \"lifetime\": \"{number} [default=1] - Number of times the fixture can be consumed before getting removed, use 0 for unlimited consumption\"\n      }\n    },\n    \"responses\": \"{array} [default=[]] - Array of responses\"\n  }\n]\n```\n\nExamples:\n\n```json\n[\n  {\n    \"request\": {\n      \"method\": \"GET\",\n      \"path\": \"/pandas\"\n    },\n    \"response\": {\n      \"body\": [{ \"id\": \"1\" }, { \"id\": \"2\" }]\n    }\n  },\n  {\n    \"request\": {\n      \"method\": \"GET\",\n      \"path\": \"/cdn/images/fennec.jpg\"\n    },\n    \"response\": {\n      \"filepath\": \"/absolute/path/tofennec.jpg\"\n    }\n  }\n]\n```\n\n**Responses**\n\n- Status 200 - OK\n\n```json\n[\n  {\n    \"id\": \"{string}\"\n  }\n]\n```\n\nExample:\n\n```json\n[\n  {\n    \"id\": \"38ed32e9fb0a1e5c7cb1b6f0ff43f6060d8b4508\"\n  },\n  {\n    \"id\": \"086c67ef89fd832deeae33b209e6e8ecc6b32003\"\n  }\n]\n```\n\n- Status 400 - BAD REQUEST\n\nThe fixture is not valid\n\n- Status 409 - CONFLICT\n\nAnother fixture with the same request is already registered\n\n\u003cbr/\u003e\n\n### \u003cimg src=\"https://img.shields.io/badge/DELETE-f93e3e.svg\" alt=\"DELETE\" /\u003e /\\_\\_\\_fixtures/:id - **Delete a fixture**\n\n**Request**\n\n- Params\n\n```json\n{\n  \"id\": \"{string}\"\n}\n```\n\nExample:\n\n```\n    DELETE /___fixtures/38ed32e9fb0a1e5c7cb1b6f0ff43f6060d8b4508\n```\n\n**Responses**\n\n- Status 204 - NO CONTENT\n\n\u003cbr/\u003e\n\n### \u003cimg src=\"https://img.shields.io/badge/DELETE-f93e3e.svg\" alt=\"DELETE\" /\u003e /\\_\\_\\_fixtures - **Delete all fixtures**\n\n**Responses**\n\n- Status 204 - NO CONTENT\n\n## Next features\n\n- Handle other web protocols like https or websocket\n- Security tokens for public environments\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevside%2Fdynamock","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevside%2Fdynamock","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevside%2Fdynamock/lists"}