Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

atlantisbot-api

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

atlantisbot-api

Django App to interface with the AtlantisBot API

  • 1.0.12
  • PyPI
  • Socket score

Maintainers
1

AtlantisBot API (Django App)

This is a Django App made to create an API that interfaces with AtlantisBot's Database.


Setup

  • Install the app

    # Or 'pip install atlantisbot-api'
    poetry add atlantisbot-api
    
  • Add "atlantisbot_api" to your INSTALLED_APPS (in settings.py):

    INSTALLED_APPS = [
        ...
        'atlantisbot_api'
    ]
    
  • (Optional, Discord Oauth) Setup Discord Oauth settings and API keys in your settings.py (sensitive configuration)

    DISCORD_OAUTH2_CLIENT_ID = 'CLIENT_ID'
    DISCORD_OAUTH2_CLIENT_SECRET = 'CLIENT_SECRET'
    DISCORD_OAUTH2_REDIRECT_URI = 'https://your-website-callback-url.com'
    
    DISCORD_API_BASE_URL = 'https://discord.com/api/v6'
    DISCORD_AUTHORIZATION_BASE_URL = DISCORD_API_BASE_URL + '/oauth2/authorize'
    DISCORD_TOKEN_URL = DISCORD_API_BASE_URL + '/oauth2/token'
    if 'http://' in DISCORD_OAUTH2_REDIRECT_URI:
        os.environ['OAUTHLIB_INSECURE_TRANSPORT'] = 'true'
    
  • Include API paths in your project urls.py:

    path('atlantisbot/', include('atlantisbot_api.urls'))
    
  • Run python manage.py migrate to create the atlantisbot models.

  • Your API paths should now be running at the following routes:

    # Database API Routes
    /atlantisbot/api/
    
    # Discord API Oauth routes
    /atlantisbot/api/oauth/user/
    /atlantisbot/api/oauth/authorize/
    

Docs

Management Commands

  • python manage.py clear_secretsanta

    • Clears receiving and giving_to fields on every Secret Santa entry
  • python manage.py roll_secretsanta

    • Make pairs for Secret Santa

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc