Skip to main content

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

Project description

cops.py

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 u-copsapi

Import

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

Get user(s):

# 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")

Getting multiple users

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")

Get server status:

from copspy import get_server_status
# Get all servers
get_server_status.get_all()

Developed by:

VyPER

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

copspy-0.1-py3-none-any.whl (4.5 kB view details)

Uploaded Python 3

File details

Details for the file copspy-0.1-py3-none-any.whl.

File metadata

  • Download URL: copspy-0.1-py3-none-any.whl
  • Upload date:
  • Size: 4.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for copspy-0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 086eb4eb46f29223d57bdf4f59224d8ba34be2bcbb9c39e9a1f35824f612a436
MD5 da5fb98967a2454b7b1aed222eadde3c
BLAKE2b-256 e74e786d1c0671b3750fb40c2f01ab34d7a1a75109eddedf4b7e02297f73ec3b

See more details on using hashes here.

Supported by

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