AIARCOASC Docs

Quickstart

Five minutes from signup to invoking your first AIARCO function.

What it is

This quickstart deploys a Python function on the ephemeral function runtime, invokes it with a payload, and shows you the logs. You will need: a verified AIARCO account, an API key with the functions:write scope, and Python 3.10+.

When to use it

  • Verify your credentials work before building something real.
  • Get a feel for the CLI, SDK and dashboard at the same time.
  • Lay down the project structure used in the rest of the docs.

Quickstart

# 1. Install the SDK + CLI
pip install aiarco
 
# 2. Authenticate (opens a browser, persists token in ~/.aiarco/config)
asc auth login
 
# 3. Create a project + scoped key
asc projects create hello-world
asc keys create dev --project hello-world --scopes functions:write,functions:read
 
# 4. Write a function file
cat > handler.py <<'PY'
def main(event):
    return {'echo': event}
PY
 
# 5. Deploy
asc functions create hello --runtime python3.12 --handler handler.main --code .
 
# 6. Invoke
asc functions invoke hello --payload '{"hello":"world"}'
 
# 7. Tail logs
asc logs tail --function hello
from aiarco import Client
 
client = Client()  # reads ASC_API_KEY from env
fn = client.functions.create(
    name='hello',
    runtime='python3.12',
    handler='handler.main',
    code_path='.',
)
result = client.functions.invoke(fn.id, payload={'hello': 'world'})
print(result.output)  # {'echo': {'hello': 'world'}}
import { Client } from '@aiarco/sdk';
 
const client = new Client();
const fn = await client.functions.create({
  name: 'hello',
  runtime: 'python3.12',
  handler: 'handler.main',
  codePath: '.',
});
const result = await client.functions.invoke(fn.id, { payload: { hello: 'world' } });
console.log(result.output);

Security

All access is authenticated and scoped. See Auth & scopes and Network controls.