← All Foundational Objects/Prefix: fun_10 Fields
AI-Agent-First Documentation
/SKILL.md
Prompt your Agent: "Query and mutate records on the 'function' table (ID prefix 'fun_') using platform.records and platform.query.sql, ensuring all lookup fields use plain string IDs."

Function (function)

Reusable code with functions and/or classes for your use.

Python SDK & PlatformContext Example
# 1. Query function via parameterized ANSI SQL
rows = await platform.query.sql("SELECT id, name, created_date FROM function ORDER BY created_date DESC LIMIT 25")

# 2. Create function record (Generates 'fun_...' Base62 ID)
created = await platform.records.create("function", [
    {"name": "Example Function"}
])
Field API NameType / FormatLookup TargetFlagsDescription
idstring—requiredId
namestring—requiredName
created_datestringdate-time—Created Date
modified_datestringdate-time—Modified Date
created_bystringlookup→ user (string ID)Created By
modified_bystringlookup→ user (string ID)Modified By
file_namestring—The name of the file
codestringcode—The actual code in this function
appstringlookup→ app (string ID)The app this function is related to
shared_withlistsharing—systemShared With