BIG-Games-LLC / ps99-public-api-docs

45 stars 5 forks source link

Introduction

The Pet Simulator 99 Public API provides access to in-game data and configuration details. With this API, developers can retrieve information about pets, items, clans, and more, allowing for the creation of external tools, websites, Discord bots, and other applications.

Usage Documentation

Below are the endpoints available in the Pet Simulator 99 Public API along with their descriptions and usage instructions:

https://docs.biggamesapi.io/

Examples of Usage

JavaScript Example:

// Example using Fetch API in JavaScript
fetch('https://ps99.biggamesapi.io/api/collections')
  .then(response => response.json())
  .then(data => console.log(data))
  .catch(error => console.error('Error:', error));

Python Example:

# Example using requests library in Python
import requests

response = requests.get('https://ps99.biggamesapi.io/api/collections')
data = response.json()
print(data)

PHP Example:

<?php
// Example using cURL in PHP
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://ps99.biggamesapi.io/api/collections',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'GET',
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
?>

Standard Responses:

The API follows a standard response format for successful and error responses:

Caching Policy:

Data from the API is cached for 60 seconds, except for Recent Average Price (RAP) data, which is cached for 4 hours.

Rate Limiting:

We encourage users to avoid spamming the API with excessive requests. Please cache your requests and limit requests to 100 per minute per IP address.

Versioning:

We strive to maintain backward compatibility with all API versions. Any changes that may affect existing integrations will be clearly documented in the changelog.

Contact Information:

For any inquiries, feedback, or support requests related to the Pet Simulator 99 Public API, please open an issue on the GitHub repository.

Explore the endpoints and integrate them into your applications! Happy coding!