Skip to main content

a fan made python API wrapper for the c-ops public api

Project description

copspy

copspy is a python API wrapper for the public version of the Critical Ops API. This project is not affiliated with c-ops, Critical Force, Critical Force Oy or any related company. This project is purely made for fun by the community and for the community.

Install:

  python -m pip install copspy 

Import

  from copspy import get_profile
  from copspy.errors import apierror # For error handling

Ussage examples:

# Get a player profile:
from copspy import get_profile
get_profile.get_player_by_ign("username here")

get_profile.get_player_by_id("id here")

Returns:

When called, the functions will return in json format. Which you can then use for your projects.

Adiditonal stuff

You can provide multiple usernames or ids.As long as you separate them with a , Such as:

get_profile.get_player_by_ign("usernme1, username2")

# or
get_profile.get_player_by_id("1234, 5678")

Developed by:

Kitsune

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

u-copsapi-0.1.tar.gz (3.5 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page