{"id":20790369,"url":"https://github.com/paragonie/quill","last_synced_at":"2025-06-30T08:07:40.932Z","repository":{"id":52802376,"uuid":"113936896","full_name":"paragonie/quill","owner":"paragonie","description":"Library for quickly and easily writing data to a Chronicle instance","archived":false,"fork":false,"pushed_at":"2024-05-08T17:16:03.000Z","size":25,"stargazers_count":21,"open_issues_count":0,"forks_count":1,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-08-10T10:38:17.995Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/paragonie.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":"2017-12-12T03:08:59.000Z","updated_at":"2024-05-08T17:14:30.000Z","dependencies_parsed_at":"2022-08-23T21:00:14.037Z","dependency_job_id":null,"html_url":"https://github.com/paragonie/quill","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paragonie%2Fquill","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paragonie%2Fquill/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paragonie%2Fquill/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/paragonie%2Fquill/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/paragonie","download_url":"https://codeload.github.com/paragonie/quill/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225040289,"owners_count":17411462,"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-11-17T15:34:23.525Z","updated_at":"2024-11-17T15:34:24.374Z","avatar_url":"https://github.com/paragonie.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Quill\n\n[![Build Status](https://github.com/paragonie/quill/actions/workflows/ci.yml/badge.svg)](https://github.com/quill/actions)\n[![Latest Stable Version](https://poser.pugx.org/paragonie/quill/v/stable)](https://packagist.org/packages/paragonie/quill)\n[![Latest Unstable Version](https://poser.pugx.org/paragonie/quill/v/unstable)](https://packagist.org/packages/paragonie/quill)\n[![License](https://poser.pugx.org/paragonie/quill/license)](https://packagist.org/packages/paragonie/quill)\n[![Downloads](https://img.shields.io/packagist/dt/paragonie/quill.svg)](https://packagist.org/packages/paragonie/quill)\n\nQuill is a library for publishing data to a [Chronicle](https://github.com/paragonie/chronicle) instance.\n**Requires PHP 7.1 or newer. PHP 7.2+ is recommended.**\n\nA [monolog handler](https://github.com/paragonie/monolog-quill) is also available. \n\n## Installing\n\n```sh\ncomposer require paragonie/quill\n```\n\n## Usage\n\n```php\n\u003c?php\n\nuse ParagonIE\\ConstantTime\\Base64UrlSafe;\nuse ParagonIE\\Quill\\Quill;\nuse ParagonIE\\Sapient\\CryptographyKeys\\{\n    SigningSecretKey,\n    SigningPublicKey\n};\n\n$quill = (new Quill())\n    -\u003esetChronicleURL('https://chronicle-public-test.paragonie.com/chronicle')\n    -\u003esetServerPublicKey(\n        new SigningPublicKey(\n            Base64UrlSafe::decode('3BK4hOYTWJbLV5QdqS-DFKEYOMKd-G5M9BvfbqG1ICI=')\n        )\n    )\n    -\u003esetClientID('**Your Client ID provided by the Chronicle here**')\n    -\u003esetClientSecretKey(\n        new SigningSecretKey('/* Loaded from the filesystem or something. */')\n    );\n\n$quill-\u003ewrite(\"Important security notice goes here.\");\n```\n\n### Writing Data (Unencrypted)\n\nThere are two main API methods that do the same thing but differ in their return\nvalues:\n\n* `write(string $input): ResponseInterface`\n  * Returns the PSR-7 Response object, or throws an exception\n* `blindWrite(string $input): bool`\n  * Returns `TRUE` or `FALSE`\n\n### Writing Data (Symmetric Encryption)\n\nIf you want to encrypt your messages using a [shared encryption key](https://github.com/paragonie/sapient/blob/master/docs/Internals/CryptographyKey.md):\n\n* `writeEncrypted(string $input, SharedEncryptionKey $key): ResponseInterface`\n  * Returns the PSR-7 Response object, or throws an exception\n* `blindWriteEncrypted(string $input, SharedEncryptionKey $key): bool`\n  * Returns `TRUE` or `FALSE`\n\n### Writing Data (Asymmetric Encryption)\n  \nIf you want to encrypt your messages using a [public-key cryptography](https://github.com/paragonie/sapient/blob/master/docs/Internals/CryptographyKey.md):\n\n* `writeSealed(string $input, SealingPublicKey $key): ResponseInterface`\n  * Returns the PSR-7 Response object, or throws an exception\n* `blindWriteSealed(string $input, SealingPublicKey $key): bool`\n  * Returns `TRUE` or `FALSE`\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparagonie%2Fquill","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fparagonie%2Fquill","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fparagonie%2Fquill/lists"}