{"repo":"rameerez/api_keys","free":true,"listed":false,"github":"https://github.com/rameerez/api_keys","clone":"git clone https://github.com/rameerez/api_keys.git","description":"🔑 Secure API keys for your Rails app","language":"Ruby","stars":41,"topics":["api","api-client","api-rest","api-server","apis","auth","authentication","authorization","bearer-authentication","bearer-tokens"],"license":"MIT","category":"auth-billing-email","readme_excerpt":"🔑 api keys – Secure API keys for your Rails app [!TIP] 🚀 Ship your next Rails app 10x faster! I've built RailsFast , a production-ready Rails boilerplate template that comes with everything you need to launch a software business in days, not weeks. Go check it out! api keys makes it simple to add secure, production-ready API key authentication to any Rails app. Generate keys, restrict scopes, auto-expire tokens, revoke tokens, and gate endpoints. It also provides a self-serve dashboard for users to issue and manage their own API keys. Secret tokens are hashed and shown only once. Plaintext is stored only for a key type that you explicitly mark as public, non-revocable, and limited to a finite permission set. 🟢 [Live interactive demo website ] Check out my other 💎 Ruby gems: allgood · usage credits · profitable · nondisposable Installation Add this line to your application's Gemfile: And then bundle install . After the gem is installed, run the generator and migration: And you're done! Upgrading an existing installation Install the bounded bcrypt authentication lookup index before deploying the current hardening changes: The generated migration is idempotent and uses a concurrent PostgreSQL index where supported. Quick Start Just add has api keys to your desired model. For example, if you want your User records to have API keys, you'd have: You can also customize how many maximum keys your users can have by passing a block to has api keys , like this: It'd work the same if","default_branch":null,"files":null,"tree":[],"storefront":"/r/rameerez","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/rameerez/api_keys/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}