Skip to main content
# PretendAPI

PretendAPI is an asynchronous wrapper for the Pretend API, designed to simplify 
the process of fetching user information from the official Pretend API.

## Features

- Asynchronous requests using `aiohttp`
- Dot notation access to JSON responses
- Rate limiting support
- Handles exceptions gracefully

## Installation

You can install the package via pip:

```bash
pip install pretendapi

Methods

get_userinfo(user_id: int)

Fetches user information about a Discord user.

  • Parameters:
    • user_id (int): The user ID of the user.
  • Returns: User information with dot notation access.

get_tiktok_user(username: str)

Fetches information about a TikTok user.

  • Parameters:
    • username (str): The TikTok username.
  • Returns: TikTok user information with dot notation access.

get_instagram_user(username: str)

Fetches information about an Instagram user.

  • Parameters:
    • username (str): The Instagram username.
  • Returns: Instagram user information with dot notation access.

get_twitter_user(username: str)

Fetches information about a Twitter user.

  • Parameters:
    • username (str): The Twitter username.
  • Returns: Twitter user information with dot notation access.

get_roblox_user(username: str)

Fetches information about a Roblox user.

  • Parameters:
    • username (str): The Roblox username.
  • Returns: Roblox user information with dot notation access.

get_signed_biolink(username: str)

Fetches information about a signed.bio user.

  • Parameters:
    • username (str): The signed.bio username.
  • Returns: signed.bio user information with dot notation access.

Usage

Here's a basic example of how to use the PretendAPI:

import asyncio
from pretendapi import PretendAPI

async def main():
    api_wrapper = PretendAPI(api_key="YOUR_API_KEY")
    
    
    user_info = await api_wrapper.get_userinfo(user_id=123456789)
    
    
    print(user_info.username)  

asyncio.run(main())

License

This project is licensed under the MIT License. See the LICENSE file for details.

Release files for pretendapi 0.1.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pretendapi 0.1.4
File Size Uploaded
pretendapi-0.1.4.tar.gz 6.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pretendapi 0.1.4
File Interpreter ABI Platform
pretendapi-0.1.4-py3-none-any.whl Python 3 none any Details

Total release size: 12.0 kB

Release files / pretendapi-0.1.4.tar.gz

Download URL pretendapi-0.1.4.tar.gz
Size 6.0 kB
Tags Source
SHA-256 checksum
How to use checksums
0ffcf838ee1806ab32accb6b26963b5fa7e4924a250ba58f82af0b3563811b4d
BLAKE2b-256 checksum
How to use checksums
5074f40b55fe5b259f6dff63a536ad66cc8e22474537bb9919cb6c98080a93a4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.5

Release files / pretendapi-0.1.4-py3-none-any.whl

Download URL pretendapi-0.1.4-py3-none-any.whl
Size 6.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2b1c5e485e20d98d37c86a8025badf20234fa8b0105c0be7eb5487048250dbd5
BLAKE2b-256 checksum
How to use checksums
f05aa7bdf81e92a314d1cb94eea6f60c66b740eb25af3c1319f477672a70d9e3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.5

Release history Release notifications | RSS feed

This release

0.1.4 This release

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page