Retrieve a the content of a specific Function Version resource.

Add MCP server to your AI tool

Allow AI tools and LLMs to interact with the API documentation portal through MCP.

MCP server URL

https://twilio.demo.bump-doc.com/doc/serverless/mcp

Standard setup for AI tools providing an mcp.json file

mcp.json
"Serverless MCP server": {
  "url": "https://twilio.demo.bump-doc.com/doc/serverless/mcp"
}
Close
GET /v1/Services/{ServiceSid}/Functions/{FunctionSid}/Versions/{Sid}/Content

The code of a Function Version.

Retrieve a the content of a specific Function Version resource.

Path parameters

  • ServiceSid string Required

    The SID of the Service to fetch the Function Version content from.

  • FunctionSid string Required

    The SID of the Function that is the parent of the Function Version content to fetch.

    Minimum length is 34, maximum length is 34. Format should match the following pattern: ^ZH[0-9a-fA-F]{32}$.

  • Sid string Required

    The SID of the Function Version content to fetch.

    Minimum length is 34, maximum length is 34. Format should match the following pattern: ^ZN[0-9a-fA-F]{32}$.

Responses

  • 200 application/json

    OK

    Hide headers attributes Show headers attributes
    • Access-Control-Allow-Origin string

      Specify the origin(s) allowed to access the resource

    • Access-Control-Allow-Methods string

      Specify the HTTP methods allowed when accessing the resource

    • Access-Control-Allow-Headers string

      Specify the headers allowed when accessing the resource

    • Access-Control-Allow-Credentials boolean

      Indicates whether the browser should include credentials

    • Access-Control-Expose-Headers string

      Headers exposed to the client

    Hide response attributes Show response attributes object
    • sid string | null

      The unique string that we created to identify the Function Version resource.

      Minimum length is 34, maximum length is 34. Format should match the following pattern: ^ZN[0-9a-fA-F]{32}$.

    • account_sid string | null

      The SID of the Account that created the Function Version resource.

      Minimum length is 34, maximum length is 34. Format should match the following pattern: ^AC[0-9a-fA-F]{32}$.

    • service_sid string | null

      The SID of the Service that the Function Version resource is associated with.

      Minimum length is 34, maximum length is 34. Format should match the following pattern: ^ZS[0-9a-fA-F]{32}$.

    • function_sid string | null

      The SID of the Function that is the parent of the Function Version.

      Minimum length is 34, maximum length is 34. Format should match the following pattern: ^ZH[0-9a-fA-F]{32}$.

    • content string | null

      The content of the Function Version resource.

    • url string(uri) | null
GET /v1/Services/{ServiceSid}/Functions/{FunctionSid}/Versions/{Sid}/Content
curl \
 --request GET 'https://serverless.twilio.com/v1/Services/{ServiceSid}/Functions/{FunctionSid}/Versions/{Sid}/Content' \
 --user "username:password"
Response examples (200)
{
  "sid": "ZN00000000000000000000000000000000",
  "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
  "service_sid": "ZS00000000000000000000000000000000",
  "function_sid": "ZH00000000000000000000000000000000",
  "content": "exports.handler = function (context, event, callback) {\n    const request = require(\"request\");\n    return request(\"http://www.google.com\", function (error, response, body) {\n        callback(null, response.statusCode);\n    });\n};",
  "url": "https://serverless.twilio.com/v1/Services/ZS00000000000000000000000000000000/Functions/ZH00000000000000000000000000000000/Versions/ZN00000000000000000000000000000000/Content"
}