{"id":23722652,"url":"https://github.com/remko/ajv-content-encoding","last_synced_at":"2026-02-15T00:30:14.588Z","repository":{"id":35206850,"uuid":"216196459","full_name":"remko/ajv-content-encoding","owner":"remko","description":"Plugin to validate strings with `contentEncoding` in AJV","archived":false,"fork":false,"pushed_at":"2022-02-12T15:59:44.000Z","size":209,"stargazers_count":0,"open_issues_count":7,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-31T08:46:10.696Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/remko.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}},"created_at":"2019-10-19T11:35:04.000Z","updated_at":"2019-10-19T12:31:08.000Z","dependencies_parsed_at":"2022-08-08T06:01:32.504Z","dependency_job_id":null,"html_url":"https://github.com/remko/ajv-content-encoding","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/remko%2Fajv-content-encoding","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/remko%2Fajv-content-encoding/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/remko%2Fajv-content-encoding/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/remko%2Fajv-content-encoding/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/remko","download_url":"https://codeload.github.com/remko/ajv-content-encoding/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239818064,"owners_count":19702064,"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":"2024-12-30T23:55:11.634Z","updated_at":"2026-02-15T00:30:14.558Z","avatar_url":"https://github.com/remko.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ajv-content-encoding: Plugin for `contentEncoding` validation in AJV\n\nAdds support to [AJV](https://github.com/epoberezkin/ajv) for validating \nstrings with [`contentEncoding`](https://json-schema.org/draft-07/json-schema-validation.html#rfc.section.8).\n\nSupports the types defined in [RFC2045](https://tools.ietf.org/html/rfc2045#section-6.1): \n`base64`, `7bit`, `8bit`, `binary`, and `quoted-printable`.\n\n## Install\n\n    yarn add ajv-content-encoding\n\nor\n\n    npm install ajv-content-encoding\n\n## Usage \n\n    const Ajv = require('ajv');\n    const ajv = require('ajv-content-encoding')(new Ajv());\n\n    const validate = ajv.compile({\n      type: \"string\",\n      contentEncoding: \"base64\"\n    });\n\n    validate(\"aGVsbG8K\"); // true\n    validate(\"invalid\"); // false\n\n\n## Caveats\n\n- The values of `contentEncoding` should be all-lowercase, and are case-sensitive\n  (i.e. `base64`, `7bit`, `8bit`, `binary`, and `quoted-printable`).\n- The `quoted-printable` validation does not validate all constraints on quoted-printable encodings. \n  E.g., it is more forgiving in when to allow newline characters etc.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fremko%2Fajv-content-encoding","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fremko%2Fajv-content-encoding","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fremko%2Fajv-content-encoding/lists"}