Skip to main content

An api wrapper for Free Rider HD

Reason this release was yanked:

Not all files were included in the project folder.

Project description

Wiki documentation

Installation

pip install frpy

Example usage

from frpy import Client

client = Client()

# Create event listener
def ready(self):
	print("Ready!")

# Add event listener
client.on("ready", ready)

# Authentication
# token = Client.get_token(
# 	username='username',
# 	password='password'
# )

client.login("token")

Data Retrievers

Retrieving user info:

from frpy.rest import get_user

username = "Guest"
user = get_user(username)

print(user.toJSON())

Expected Output:

{
	"admin": false,
	"avatar": "https://cdn.freeriderhd.com/free_rider_hd/sprites/guest_profile_v2.png",
	"classic": false,
	"cosmetics": {
		"head": {
			"img": "head_icons_4 head_icons_4-classic"
		}
	},
	"createdTracks": [],
	"displayName": "Guest",
	"forums": null,
	"friendLimitReached": false,
	"friends": [],
	"id": 0,
	"likedTracks": [],
	"mobileStats": {
		"connected": "1",
		"headCount": "--",
		"level": "--",
		"wins": "--"
	},
	"moderator": false,
	"plus": false,
	"recentlyCompleted": [],
	"recentlyPlayed": [],
	"stats": {
		"comments": 0,
		"completed": 0,
		"created": 0,
		"headCount": 1,
		"rated": 0,
		"totalHeadCount": 200,
		"totalPoints": 0
	},
	"username": "guest"
}

Retrieving track data:

from frpy.rest import get_track

track_id = 1001
track = get_track(track_id)

print(track.toJSON())

Expected Output:

{
	"author": "weewam",
	"comments": [],
	"createdAt": "11/19/13",
	"createdDateAgo": "9 years ago",
	"description": "Wild West is a Free Rider community classic track by weewam.",
	"featured": false,
	"hidden": 0,
	"id": 1001,
	"maxCommentLength": 500,
	"size": 66,
	"stats": {
		"averageRating": 79,
		"averageTime": "38:37.83",
		"completionRate": 0.03,
		"downVotes": 67,
		"firstRuns": null,
		"plays": "59.5k",
		"runs": 571,
		"upVotes": 257,
		"votes": 324
	},
	"thumbnail": "https://cdn.freeriderhd.com/free_rider_hd/tracks/prd/b/8c/1001/768x250-v5.png",
	"title": "Wild West",
	"trackOfTheDay": {
		"entries": [],
		"gems": 500,
		"lives": 30,
		"refillCost": 10
	},
	"vehicle": "MTB",
	"vehicles": [
		"BMX",
		"MTB"
	]
}

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

frpy-0.3.0.tar.gz (20.5 kB view details)

Uploaded Source

Built Distribution

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

frpy-0.3.0-py3-none-any.whl (21.0 kB view details)

Uploaded Python 3

File details

Details for the file frpy-0.3.0.tar.gz.

File metadata

  • Download URL: frpy-0.3.0.tar.gz
  • Upload date:
  • Size: 20.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for frpy-0.3.0.tar.gz
Algorithm Hash digest
SHA256 9eb8897d74030c5985d6d1460e69b5788dc906bf99a80c9035875af1b2a19df4
MD5 c54b15ec5463fcd239034c75c1ae8230
BLAKE2b-256 925462654a5f3da3066c9c17d050e0f0d1d494ab20981d82f59045d16f5a795d

See more details on using hashes here.

Provenance

The following attestation bundles were made for frpy-0.3.0.tar.gz:

Publisher: python-publish.yml on Calculamatrise/frpy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file frpy-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: frpy-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 21.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for frpy-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8e9b094b2634b1b9cb33e204634a25d34e070993b4d40203a720104f2f8f2204
MD5 d755fb6f908285420ee9eab92328670d
BLAKE2b-256 89eeefdfd9c5026f92941804fafd0df082e5ea41d590a8296dde0a08b8e8ee4f

See more details on using hashes here.

Provenance

The following attestation bundles were made for frpy-0.3.0-py3-none-any.whl:

Publisher: python-publish.yml on Calculamatrise/frpy

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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