{"id":22061829,"url":"https://github.com/goshatch/atproto-clojure","last_synced_at":"2025-07-24T01:32:13.251Z","repository":{"id":264194805,"uuid":"892658845","full_name":"goshatch/atproto-clojure","owner":"goshatch","description":"🦋 atproto Clojure SDK","archived":false,"fork":false,"pushed_at":"2024-11-27T17:11:47.000Z","size":162,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-11-30T14:26:09.622Z","etag":null,"topics":["atproto","atprotocol","bluesky","clojure","sdk"],"latest_commit_sha":null,"homepage":"","language":"Clojure","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/goshatch.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}},"created_at":"2024-11-22T14:28:42.000Z","updated_at":"2024-11-28T15:00:10.000Z","dependencies_parsed_at":"2024-11-22T15:44:15.387Z","dependency_job_id":null,"html_url":"https://github.com/goshatch/atproto-clojure","commit_stats":null,"previous_names":["goshatch/atproto-clojure"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goshatch%2Fatproto-clojure","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goshatch%2Fatproto-clojure/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goshatch%2Fatproto-clojure/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/goshatch%2Fatproto-clojure/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/goshatch","download_url":"https://codeload.github.com/goshatch/atproto-clojure/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227391736,"owners_count":17773037,"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":["atproto","atprotocol","bluesky","clojure","sdk"],"created_at":"2024-11-30T18:15:12.440Z","updated_at":"2025-07-24T01:32:13.239Z","avatar_url":"https://github.com/goshatch.png","language":"Clojure","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp\u003e\n  \u003cimg src=\"https://raw.github.com/goshatch/atproto-clojure/main/resources/logo.png\"\n  alt=\"Absolute Terror Protocol\"\n  style=\"max-width:300px;\" /\u003e\n\u003c/p\u003e\n\n# atproto Clojure SDK\n\n⚠️ Work on this SDK has been paused (see [this bsky post](https://bsky.app/profile/gosha.net/post/3lhstloh6s22n)). If anyone would like to fork the project and continue the work, you are very welcome to do so!\n\n## Progress\n\n| Feature      | Status |\n| ------------ | ------ |\n| http client  | 🟡     |\n| identifiers  | 🔴     |\n| bsky         | 🔴     |\n| crypto       | 🔴     |\n| mst          | 🔴     |\n| lexicon      | 🔴     |\n| identity     | 🔴     |\n| streaming    | 🟡     |\n| service auth | 🔴     |\n| plc          | 🔴     |\n| oauth server | 🔴     |\n\n## Usage\n\n### HTTP client\n\nThe client is using [Martian](https://github.com/oliyh/martian/) under the hood to handle the HTTP endpoints [published](https://github.com/bluesky-social/bsky-docs/tree/main/atproto-openapi-types) by the Bsky team in OpenAPI format\n\n```clojure\n(require '[net.gosha.atproto.client :as at])\n\n;; Unauthenticated client\n(def session (at/init :base-url \"https://public.api.bsky.app\"))\n\n;; Authenticated client\n(def session (at/init :username \"me.bsky.social\"\n                      :app-password \"SECRET\"\n                      :base-url \"https://bsky.social\"))\n\n\n;; Bluesky endpoints and their query params can be found here:\n;; https://docs.bsky.app/docs/category/http-reference\n(let [resp (at/call session :app.bsky.actor.get-profile {:actor \"gosha.net\"})]\n  (select-keys (:body @resp) [:handle :displayName :createdAt :followersCount]))\n;; =\u003e {:handle \"gosha.net\",\n;; :displayName \"Gosha ⚡\",\n;; :createdAt \"2023-05-08T19:08:05.781Z\",\n;; :followersCount 617}\n```\n\n### Jetstream\n\nConnect to Bluesky's [Jetstream service](https://docs.bsky.app/blog/jetstream) to get real-time updates of public network data. Jetstream provides a JSON-based alternative to the binary CBOR firehose, making it easier to work with post streams, likes, follows, and other events.\n\n```clojure\n(require '[net.gosha.atproto.jetstream :as jetstream]\n         '[clojure.core.async          :as async]\n         '[examples.jetstream-analysis :as analysis]))\n\n;; Connect with default settings (subscribes to posts)\n(def conn (jetstream/connect-jetstream (async/chan 1024)))\n\n;; Print out a single post (with 5 second timeout)\n(let [event (async/alt!!\n             (:events conn)    ([v] v)\n             (async/timeout 5000) :timeout)]\n  (clojure.pprint/pprint event))\n\n;; Start analyzing the stream\n(def analysis (analysis/start-analysis conn))\n\n;; Get current statistics about post rates, sizes, etc\n(analysis/get-summary @(:state analysis))\n\n;; Save sample messages for offline analysis\n(analysis/collect-samples conn\n                        {:count    10\n                         :filename \"samples/my-samples.json\"})\n\n;; Cleanup\n(analysis/stop-analysis analysis)\n(jetstream/disconnect conn)\n```\n\nCheck out the `examples.jetstream-analysis` namespace for a complete example of stream processing and analysis.\n\n## References\n\n- [Existing SDKs](https://atproto.com/sdks)\n- [What goes in to a Bluesky or atproto SDK?](https://github.com/bluesky-social/atproto/discussions/2415)\n- [atproto Interop Test Files](https://github.com/bluesky-social/atproto-interop-tests)\n\n## Contribute\n\nHelp is very much welcomed!\n\nBefore submitting a pull request, please take a look at the [Issues](https://github.com/goshatch/atproto-clojure/issues) to see if the topic you are interested in is already being discussed, and if it is not, please create an Issue to discuss it before making a PR.\n\nFor anything else, please reach out on 🦋: [@gosha.net](https://bsky.app/profile/gosha.net)!\n\n## License\n\nMIT, see LICENSE file\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoshatch%2Fatproto-clojure","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgoshatch%2Fatproto-clojure","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoshatch%2Fatproto-clojure/lists"}