{"id":13832594,"url":"https://github.com/barkyq/gnost-deflate-client","last_synced_at":"2025-07-09T19:30:42.714Z","repository":{"id":65963403,"uuid":"603290450","full_name":"barkyq/gnost-deflate-client","owner":"barkyq","description":"go nostr client implementing permessage-deflate websocket compression","archived":false,"fork":false,"pushed_at":"2023-02-22T03:49:58.000Z","size":79,"stargazers_count":7,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-08-04T11:01:17.454Z","etag":null,"topics":["nostr"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/barkyq.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":"2023-02-18T03:46:12.000Z","updated_at":"2024-06-13T23:29:59.000Z","dependencies_parsed_at":"2023-02-25T11:45:32.551Z","dependency_job_id":null,"html_url":"https://github.com/barkyq/gnost-deflate-client","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/barkyq%2Fgnost-deflate-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/barkyq%2Fgnost-deflate-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/barkyq%2Fgnost-deflate-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/barkyq%2Fgnost-deflate-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/barkyq","download_url":"https://codeload.github.com/barkyq/gnost-deflate-client/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225581782,"owners_count":17491788,"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":["nostr"],"created_at":"2024-08-04T11:00:23.428Z","updated_at":"2024-11-20T15:30:51.300Z","avatar_url":"https://github.com/barkyq.png","language":"Go","funding_links":[],"categories":["Install from Source","Clients"],"sub_categories":["Nostr","Other"],"readme":"# gnost-deflate-client\ngo nostr client implementing [permessage-deflate websocket compression](https://www.rfc-editor.org/rfc/rfc7692#section-7). Downloads the results of a REQ query, saving the results in [jsonl format](https://jsonlines.org/), and logs to `stderr` some stats related to the compression.\n\n## Building\nIn cloned repository run `go build .` to build the executable `gnost-deflate-client`.\n\n## Running\nAccepts an array of filter json objects on stdin, and saves the returned events to a `.jsonl` file:\n``` zsh\necho '[{\n\"authors\":[\"3bf0c63fcb93463407af97a5e5ee64fa883d107ef9e558472c4eb9aaaefa459d\"],\n\"since\":1676600000\n}]' | ./gnost-deflate-client --port 443 --scheme wss --host nos.lol --output events.jsonl\n```\n\n#### Keep connection alive\nUse the `--keepalive N` option to keep the connection alive, sending a PING frame to the relay every `N` seconds. New returned events will be appended to the `--output` file. Enter `C-c` to cleanly shutdown the listener.\n\n#### Compatibility with relays\nSet the output to `-` in order to print the returned events to `stdout`. This can be composed with the `import` command for a local instance of [gnost-relay](https://github.com/barkyq/gnost-relay) or [strfry](https://github.com/hoytech/strfry)\n```zsh\necho '[{\"since\":1676863922,\"kinds\":[1]}]' |\\\ngnost-deflate-client --port 443 --scheme wss --host nos.lol --keepalive 30 --output - |\\\nDATABASE_URL=postgres://x gnost-relay --import\n```\n```zsh\necho '[{\n\"authors\":[\"3bf0c63fcb93463407af97a5e5ee64fa883d107ef9e558472c4eb9aaaefa459d\"],\n\"since\":1676600000\n}]' | ./gnost-deflate-client --port 443 --scheme wss --host nos.lol --output - | strfry import\n```\nNote that `strfry import` is not compatible with `--keepalive` since `strfry` expects an `EOF` from `stdin`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbarkyq%2Fgnost-deflate-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbarkyq%2Fgnost-deflate-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbarkyq%2Fgnost-deflate-client/lists"}