Scripts
Retrieve a specific script

GET /api/v2/script/

This API endpoint retrieves a script by its id.

Parameters

NameTypeDescription
idstringThe unique identifier of the script to retrieve.

Response

The response is a JSON object with one of the following structures:

Success Response

{
  "script": [
    {
      "_id": "66f29856c7543f330a52838d",
      "title": "New Spin For Free Script | OP | Global Nuker | More...",
      "views": 258,
      "private": false,
      "likes": 0,
      "dislikes": 0,
      "keySystem": true,
      "mobileReady": true,
      "lastUpdated": "2024-09-24T10:45:42.277Z",
      "createdAt": "2024-09-24T10:45:42.277Z",
      "paid": false,
      "description": "This game is actually garbage... im surprised it even got on my FYP on roblox....",
      "image": "https://tr.rbxcdn.com/17958d7199dda72676e70cc76815310c/480/270/Image/Jpeg",
      "rawScript": "https://rscripts.net/raw/new-spin-for-free-script-or-op-or-global-nuker-or-more_1727174742280_BZCljUcmVo.txt",
      "testedExecutors": [
        {
          "_id": "66a6704b796b8cf770481380",
          "title": "Cryptic",
          "image": "https://rscripts.net/assets/executors/CrypticLogo200x200.png",
          "creator": "reaperscripts",
          "discord_url": "https://discord.gg/qM3WZhQShn",
          "downloads": 1080,
          "platforms": [
            "android"
          ],
          "download_url": "https://getcryptic.net/"
        },
        {
          "_id": "66a6ad1a796b8cf770481386",
          "title": "Codex",
          "image": "https://rscripts.net/assets/executors/CodexLogo.jpg",
          "creator": "Furky",
          "discord_url": "https://discord.gg/robloxexploits",
          "downloads": 1212,
          "platforms": [
            "android"
          ],
          "download_url": "https://codex.lol"
        },
        {
          "_id": "66ed6cbe744db12a4a161fe4",
          "title": "Synapse Z",
          "image": "https://rscripts.net/assets/executors/SynapsezLogo.webp",
          "creator": "grhofficial",
          "discord_url": "https://synapsez.net/discord",
          "downloads": 253,
          "platforms": [
            "windows"
          ],
          "download_url": "https://synapsez.net/"
        }
      ],
      "user": {
        "_id": "65cb7efca9aa5d9a728faf67",
        "username": "pcallskeleton",
        "image": "https://rscripts.net/assets/avatars/65cb7efca9aa5d9a728faf67_1707835997436_mZ8v0oseq7.webp",
        "discord": {
          "id": "897365281696018462",
          "username": "pcallskeleton"
        },
        "verified": true,
        "displayEmail": false,
        "socials": {
          "discordServer": "https://discord.gg/simplest"
        },
        "bio": "i will be better than Toon very soon...\nhttps://discord.gg/simplest",
        "admin": true,
        "lastActive": "2024-09-24T11:13:55.465Z"
      },
      "game": {
        "_id": "66e4171b50105d09f1111344",
        "title": "[✨FREE] Spin For Free! 🤑",
        "placeId": "17300798098",
        "imgurl": "https://tr.rbxcdn.com/17958d7199dda72676e70cc76815310c/480/270/Image/Jpeg",
        "last_updated": "2024-09-13T10:42:35.160Z",
        "__v": 0,
        "gameLink": "https://www.roblox.com/games/17300798098/FREE-Spin-For-Free"
      }
    }
  ]
}
⚠️

Please read about possible API Response Edge cases and handle them accordingly.

Error Responses

Missing id

{
  "error": "Please provide an id"
}

Script Not Found

{
  "error": "Script not found"
}

General Error

{
  "error": "Error message"
}

Description

The GET /api/v2/script/retrieve endpoint retrieves a script by its unique identifier (targetId). If the targetId is not provided, a 400 Bad Request error is returned with a message to provide a targetId.

If the script is found, the script object is returned in the success field of the response. If the script is not found a 400 Bad Request error is returned with a message indicating the issue.

If any other error occurs during the retrieval process, a 400 Bad Request error is returned with the error message.

Example Usage

fetch("/api/v2/script?id=65c7c91dd7dfa5be4dae6f22")
  .then((response) => response.json())
  .then((data) => {
    if (data.success) {
      console.log("Script retrieved successfully:", data.success);
    } else {
      console.error("Error retrieving script:", data.error);
    }
  })
  .catch((error) => {
    console.error("Error retrieving script:", error);
  });