Aucune description

JoostSijm 9858b3e04c Improved readme il y a 4 ans
rival_regions_wrapper baaed2455a Add setup.py and license, moved some files il y a 4 ans
.gitignore 44fe624811 Remove app, functions, and credential template il y a 5 ans
LICENSE baaed2455a Add setup.py and license, moved some files il y a 4 ans
Pipfile 865081cfba Update pipfile with correct module il y a 5 ans
Pipfile.lock 865081cfba Update pipfile with correct module il y a 5 ans
README.md 9858b3e04c Improved readme il y a 4 ans
setup.py baaed2455a Add setup.py and license, moved some files il y a 4 ans

README.md

RR-API-Wrapper

This library will functions as an API wrapper for interaction with Rival Regions.

Middleware

The API wrapper uses middleware to decide where how to send the request. Middlewares can also be used to write direct requests to Rival Regions.

Current middleware

LocalAuthentication

Use username, password, and login method to log in local instance of the authenticator.

RemoteAuthentication

Connect through a remote API using URL and authentication key.

Examples

Create local authentication middleman and log in with environ variables.

import os
from rival_regions_wrapper import LocalAuthentication

middleware = LocalAuthentication(
  os.environ["USERNAME"],
  os.environ["PASSWORD"],
  os.environ["LOGIN_METHOD"]
)

region = middleware.get('listed/upgrades/{}'.format(region_id))

Contact