Lum0x SDK
  • Lum0x-sdk
    • Getting started
    • Examples
      • Case 1 : Find my Fan
      • Case 2: Fetch user's Moxie earning
      • Case 3: Raffle events among the filtered casts
      • How to Deploy a Project with Vercel
    • FarcasterUser
      • Search for Usernames
      • Fetch users based on FIDs
      • Fetch power user objects
      • Fetches users based on Eth or Sol addresses
      • Lookup a user by custody-address
      • Retrieve all channels that a given fid follows
      • Get User Information by username
      • Get Recent Users
    • FarcasterCast
      • Retrieve cast for a given hash or Warpcast URL
      • Retrieve casts for a given user
      • Gets information about an array of casts
      • Retrieve the conversation for a given cast
      • Get Recent Casts
    • FarcasterFeed
      • Retrieve casts based on filters
      • Retrieve trending casts
    • FarcasterReaction
      • Fetches reactions for a given user
      • Fetches reactions for a given cast
    • FarcasterFollowers
      • Retrieve followers for a given user
      • Retrieve relevant followers for a given user
      • Retrieve a list of users followed by a user
    • FarcasterStorage
      • Fetches storage allocations for a given user
      • Fetches storage usage for a given user
    • FarcasterFname
      • Check if a given fname is available
    • FarcasterMute
      • Get fids that a user has muted
    • FarcasterChannel
      • Retrieve all channels with their details
      • Search for channels based on id or name
      • (Bulk) Retrieve channels by id or parent_url
      • Retrieve channel details by id or parent_url
      • Retrieve followers for a given channel
      • Get channels that a user is active in
      • Check If User Follows Channel
      • Retrieve trending channels based on activity
    • FarcasterNotification
      • Retrieve notifications for a given user
    • FarcasterMoxie
      • Retrieve Moxie earning status
      • Retrieve FarScore and FarRank
      • Retrieve Moxie airdrop claim status
      • Retrieve Moxie earning details for cast.
      • Retrieve Moxie earning details for reply.
      • Retrieve Moxie earning details for cast by fid.
      • Retrieve Moxie earning details for reply by fid.
      • Retrieve Moxie earning details from channel cast.
Powered by GitBook
On this page
  • Overview
  • Parameters
  • Usage
  • Response
  • Field Description
  1. Lum0x-sdk
  2. FarcasterCast

Gets information about an array of casts

farcasterCast.getCasts

Overview

Retrieve multiple casts using their respective hashes.

Parameters

name
type
required
Note

casts

string

true

ex) "0xfa6e2aad1b1cb8fd7037b93382c68264f77c00be,0x4e0451dc4fac217eaa39c86f3ae8b8c7174e2356"

viewer_fid

number

false

ex) 3

sort_type

string

false

"trending", "likes", "recasts", "replies" or "recent"

Usage

let res = await Lum0x.farcasterCast.getCasts({
    casts: "0xfa6e2aad1b1cb8fd7037b93382c68264f77c00be, 0x4e0451dc4fac217eaa39c86f3ae8b8c7174e2356",
    sort_type: "trending"
});
console.log(JSON.stringify(res, null, 2));

Response

{
  "result": {
    "casts": [
      {
        "object": "cast",
        "hash": "0x4e0451dc4fac217eaa39c86f3ae8b8c7174e2356",
        "thread_hash": "0x4e0451dc4fac217eaa39c86f3ae8b8c7174e2356",
        "parent_hash": null,
        "parent_url": null,
        "root_parent_url": null,
        "parent_author": {
          "fid": null
        },
        "author": {
          "object": "user",
          "fid": 721870,
          "custody_address": "0x63cd09948b05e5d8367226b0c83a16b583862191",
          "username": "lum0x",
          "display_name": "Lum0x",
          "pfp_url": "https://imagedelivery.net/BXluQx4ige9GuW0Ia56BHw/74970e01-bcf7-4ef7-31d7-238f5814b200/original",
          "profile": {
            "bio": {
              "text": "illuminate your builder journey with Lum0x πŸ’‘\n\nhttps://lum0x.com/"
            }
          },
          "follower_count": 37,
          "following_count": 2,
          "verifications": [],
          "verified_addresses": {
            "eth_addresses": [],
            "sol_addresses": []
          },
          "active_status": "inactive",
          "power_badge": false
        },
        "text": "🌟 Introducing Lum0x: Illuminating the path for Farcaster Builders! 🌟 \nWe’re transforming Farcaster data into actionable intelligence, empowering developers to create the next groundbreaking Farcaster app. \n\nReady to supercharge your web3 journey? \nJust say the magic word - Lum0x. πŸͺ„ \nhttps://lum0x.com/",
        "timestamp": "2024-06-28T04:50:29.000Z",
        "embeds": [
          {
            "url": "https://imagedelivery.net/BXluQx4ige9GuW0Ia56BHw/89d8d88f-e640-4d9d-40e5-a3c1a49afc00/original",
            "metadata": {
              "content_type": "image/jpeg",
              "content_length": "122578",
              "_status": "RESOLVED",
              "image": {
                "width_px": 800,
                "height_px": 600
              }
            }
          }
        ],
        "reactions": {
          "likes_count": 6,
          "recasts_count": 0,
          "likes": [
            {
              "fid": 464556,
              "fname": "takitiger"
            },
            {
              "fid": 249402,
              "fname": "sealordx"
            },
            {
              "fid": 5303,
              "fname": "zk-yuki.eth"
            },
            {
              "fid": 492358,
              "fname": "dbee"
            },
            {
              "fid": 531547,
              "fname": "farswag"
            }
          ],
          "recasts": []
        },
        "replies": {
          "count": 0
        },
        "channel": null,
        "mentioned_profiles": []
      },
      {
        "object": "cast",
        "hash": "0xfa6e2aad1b1cb8fd7037b93382c68264f77c00be",
        "thread_hash": "0xfa6e2aad1b1cb8fd7037b93382c68264f77c00be",
        "parent_hash": null,
        "parent_url": null,
        "root_parent_url": null,
        "parent_author": {
          "fid": null
        },
        "author": {
          "object": "user",
          "fid": 721870,
          "custody_address": "0x63cd09948b05e5d8367226b0c83a16b583862191",
          "username": "lum0x",
          "display_name": "Lum0x",
          "pfp_url": "https://imagedelivery.net/BXluQx4ige9GuW0Ia56BHw/74970e01-bcf7-4ef7-31d7-238f5814b200/original",
          "profile": {
            "bio": {
              "text": "illuminate your builder journey with Lum0x πŸ’‘\n\nhttps://lum0x.com/"
            }
          },
          "follower_count": 37,
          "following_count": 2,
          "verifications": [],
          "verified_addresses": {
            "eth_addresses": [],
            "sol_addresses": []
          },
          "active_status": "inactive",
          "power_badge": false
        },
        "text": "πŸ‘€βœ¨ Something luminous is coming to Farcaster... \n\nBuilders, are you ready to see your data in a whole new light?",
        "timestamp": "2024-06-27T06:01:14.000Z",
        "embeds": [
          {
            "url": "https://imagedelivery.net/BXluQx4ige9GuW0Ia56BHw/1b45d600-0075-4494-969c-db5c6f6ce500/original",
            "metadata": {
              "content_type": "image/jpeg",
              "content_length": "169601",
              "_status": "RESOLVED",
              "image": {
                "width_px": 800,
                "height_px": 600
              }
            }
          }
        ],
        "reactions": {
          "likes_count": 1,
          "recasts_count": 1,
          "likes": [
            {
              "fid": 5303,
              "fname": "zk-yuki.eth"
            }
          ],
          "recasts": [
            {
              "fid": 373908,
              "fname": "ty-kindleplus"
            }
          ]
        },
        "replies": {
          "count": 0
        },
        "channel": null,
        "mentioned_profiles": []
      }
    ]
  }
Hash
Author
Text
Timestamp
Likes Count
Recasts Count
Replies Count
Embed URL
Embed Metadata

0x4e0451dc4fac217eaa39c86f3ae8b8c7174e2356

Lum0x

🌟 Introducing Lum0x: Illuminating the path for Farcaster Builders! 🌟 \nWe’re transforming Farcaster data into actionable intelligence, empowering developers to create the next groundbreaking Farcaster app. \n\nReady to supercharge your web3 journey? \nJust say the magic word - Lum0x. πŸͺ„ \nhttps://lum0x.com/

2024-06-28T04:50:29.000Z

6

0

0

Content Type: image/jpeg Content Length: 122578 Image Size: 800x600 px

0xfa6e2aad1b1cb8fd7037b93382c68264f77c00be

Lum0x

πŸ‘€βœ¨ Something luminous is coming to Farcaster... \n\nBuilders, are you ready to see your data in a whole new light?

2024-06-27T06:01:14.000Z

1

1

0

Content Type: image/jpeg Content Length: 169601 Image Size: 800x600 px

Field Description

  • Cast Hash: The unique hash value of the cast.

  • Thread Hash: The hash value of the thread containing the cast.

  • Parent Hash: The hash value of the parent cast (currently none).

  • Parent URL: The URL of the parent cast (currently none).

  • Root Parent URL: The URL of the root parent cast (currently none).

  • Parent Author: The author of the parent cast (currently none).

  • Author FID: The author's unique identifier (FID).

  • Custody Address: The author's wallet address.

  • Username: The author's username.

  • Display Name: The author's display name.

  • Profile Picture URL: The URL of the author's profile picture.

  • Bio: The author's introduction text.

  • Follower Count: The number of followers the author has.

  • Following Count: The number of people the author is following.

  • Verifications: The author's verification information (currently none).

  • Verified ETH Addresses: List of verified Ethereum addresses (currently none).

  • Verified SOL Addresses: List of verified Solana addresses (currently none).

  • Active Status: The author's activity status.

  • Text: The content of the cast.

  • Timestamp: The time when the cast was created.

  • Embeds URL: URL of the embedded image.

  • Likes Count: The number of likes on the cast.

  • Recasts Count: The number of recasts of the cast.

  • Likes: List of users who liked the cast.

  • Recasts: List of users who recast the cast.

  • Replies Count: The number of replies to the cast.

  • Channel: The channel containing the cast (currently none).

  • Mentioned Profiles: List of profiles mentioned in the cast (currently none).

PreviousRetrieve casts for a given userNextRetrieve the conversation for a given cast

Last updated 9 months ago

Embed
Embed