{"id":18367702,"url":"https://github.com/rairprotocol/rair-sdk","last_synced_at":"2025-05-14T07:08:43.009Z","repository":{"id":257817302,"uuid":"864147157","full_name":"rairprotocol/rair-sdk","owner":"rairprotocol","description":"Simple developer SDK for RAIRprotocol","archived":false,"fork":false,"pushed_at":"2025-04-24T14:55:17.000Z","size":84,"stargazers_count":1633,"open_issues_count":5,"forks_count":4,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-24T15:42:06.246Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rairprotocol.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,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-09-27T15:23:36.000Z","updated_at":"2025-04-24T14:57:53.000Z","dependencies_parsed_at":null,"dependency_job_id":"1327a6cc-6913-4959-abce-31048950011f","html_url":"https://github.com/rairprotocol/rair-sdk","commit_stats":{"total_commits":42,"total_committers":3,"mean_commits":14.0,"dds":"0.23809523809523814","last_synced_commit":"47c2b10dba1aa212f7f25a49f4a2d6e871489d26"},"previous_names":["rairprotocol/rair-sdk"],"tags_count":0,"template":true,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rairprotocol%2Frair-sdk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rairprotocol%2Frair-sdk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rairprotocol%2Frair-sdk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rairprotocol%2Frair-sdk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rairprotocol","download_url":"https://codeload.github.com/rairprotocol/rair-sdk/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254092775,"owners_count":22013290,"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-05T23:23:03.067Z","updated_at":"2025-05-14T07:08:42.997Z","avatar_url":"https://github.com/rairprotocol.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"Deploying Vibe Frontend Quickly \n\nClone this repository on your own GitHub account and deploy it to Netlify:\n\n[![Netlify Deploy button](https://www.netlify.com/img/deploy/button.svg)](https://app.netlify.com/start/deploy?repository=https://github.com/rairprotocol/rair-sdk)\n\n\n# rair-sdk\n\nSimple developer SDK for RAIRprotocol. Note: Before you start you need an Admin NFT which can be minted here using Metamask and a small amount of Base Gas. If you need Base Gas please reach out to us. https://rairprotocol.xyz/collection/0x2105/0xfc3666266d129504dd6c713f9bce107747ae4aee/0/0\n\n## Getting started\n\n```\nnpm install @rair-protocol/sdk\n```\n\nAfter installing, you can import and initialize the SDK:\n\n```ts\nimport { RairSDK } from \"@rair-protocol/sdk\";\n\nconst settings = {\n  serverURL, // URL for backend. Default sandbox URL to try if you haven't deployed your own backend rair-node yet http://35.226.25.117:5000\n  socketURL, // URL for socket. http://35.226.25.117:8080\n};\n\nexport const rairSDK = new RairSDK(settings);\n```\nAfter Initializng the SDK here are the first things you can do to get a working dApp\n\n## 1. Empty dApp with Authentication working (default frontend)\n\nFollow these steps below to deploy our existing sample application\n\n```ts\nconst getChallenge = async (userAddress: Hex, ownerAddress?: Hex) =\u003e {\n  const responseData = await rairSDK.auth.getChallenge({  // use getChallenge from auth folder\n    userAddress: userAddress,\n    intent: \"login\",\n    ownerAddress: ownerAddress || userAddress,\n  });\n  return responseData.response;\n};\n```\nAll requests what you need to use you can find in `src/API`\n\n\nSome example:\n\nFor user lists\n```ts\nconst { data } = await rairSDK.users.listUsers();\n```\nRequest with arguments\n```ts\nconst responseData = await rairSDK.notifications.listNotifications({\n      pageNum: pageNum,\n    });\n```\n\nTo use the SDK you need to use rairSDK(exported above), select the desired file with requests and select the request \nExample: \nfile - `src/API/users` \nrequest - `findUserByUserAddress` \n\nResult: \n```ts\nconst userDataResponse = await rairSDK.users.findUserByUserAddress({\n        publicAddress: loginData.userAddress,\n      });\n```\n`publicAddress` is a required argument in this request\n\n\n\n## 2. Example of deploying your own frontend that interacts with our SDK to make a new dApp\n\nDemo project for rair sdk - https://github.com/rairprotocol/rair-official-library/tree/main/demo-rair-sdk\n\nmake `git clone https://github.com/rairprotocol/rair-official-library/tree/main/demo-rair-sdk` and `yarn` and `yarn start`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frairprotocol%2Frair-sdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frairprotocol%2Frair-sdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frairprotocol%2Frair-sdk/lists"}