Class Creator

Preresents a Content Creator on iFunny

Hierarchy

Constructors

Properties

#client: Client<boolean>

Client instance attached to the Object

#endpointUrl: string = Endpoints.account

Endpoint url the object will request to

#payload: APIUser

The payload of the object.

#user: null | User = null

The Content Creator's User Object

Accessors

  • get endpointUrl(): string
  • Endpoint url for requests to update the payload

    Returns string

  • set endpointUrl(value: string): void
  • Parameters

    • value: string

    Returns void

  • get isSubscriber(): boolean
  • Is the creator subscribed to the Client?

    Returns

    boolean

    Returns boolean

  • get isSubscription(): boolean
  • Is the Client subscribed to the Creator?

    Returns

    boolean

    Returns boolean

  • get nickColor(): null | "55FF00" | "660000" | "e0b400" | "a078f0" | "ff3e52" | "ffffff"
  • The creator's nick color

    Returns

    A hex color code without the # prefix

    Example

    nick_color: "55FF00"
    

    Returns null | "55FF00" | "660000" | "e0b400" | "a078f0" | "ff3e52" | "ffffff"

  • get originalNick(): string
  • The creator's original nick
    ? iFunny sometimes censors users nicknames

    Example

    nick: "garespectingyoass"
    original_nick: "garapingyoass"

    Returns string

  • get payload(): Payload
  • Get the payload of the object

    Returns Payload

  • set payload(payload: Partial<Payload>): void
  • Updates the payload of the object.

    Returns

    The current instance

    Parameters

    • payload: Partial<Payload>

      The payload to merge into the current instance

    Returns void

  • get totalPosts(): number
  • Total number of posts the creator has
    ? This isn't in Creator.num for some reason

    Returns number

Methods

  • Gets the value from the payload from its key

    Returns

    Type Parameters

    • P extends APIUser<P>

    • K extends string | number | symbol

    Parameters

    • key: K

      The key to get the value of

    Returns Nullify<P[K]>

  • When concatenated with a string, this automatically returns the user's nick instead of the User object.

    Example

    console.log(Hello from ${user}!); // Logs: Hello from iFunnyChef

    Returns string

Generated using TypeDoc