Getting Started
In this tutorial, you will build a simple API that returns a personalized greeting. By the end, you will have a deployed endpoint that responds with "Hello {name}" when called.
What you will build:
Deployed as a Lambda behind an API Gateway.
Step 1: Create a New Project
- Launch Orixen
- Click New Project
- Select a workspace folder
- Change the project name at the top (e.g.,
Hello API)
Step 2: Add an API Trigger Block
The API block creates an HTTP endpoint using AWS API Gateway.
- From the blocks panel, drag an API block onto the canvas
- Double click the block
- Configure the block:
- Path:
/hello - Method:
GET
- Path:
Step 3: Add a Function Block
The Function block contains the logic that processes the request.
- Drag a Function block onto the canvas and connect it to the API block.
- Double click the block
- Name the function
Greet Function. - Code the function:
- Click "Create Code" to get the boilerplate code
- Click "Edit Code" to open the code editor
- Select the path to your preferred code editor
-
Modify the function code as follows:
- Input: Edit the file
defaultIn.ts: -
Output: Edit the file
defaultOut.ts: -
Run Function: Edit its body to be:
- Input: Edit the file
Step 4: Add a Response Block
The Response block defines where the API response will come from.
- Drag a Response block onto the canvas
- Connect the Function block output to the Response block input
Step 5: Deploy
- Select Menu > Project > Generate Deploy Code
- Select Menu > Project > Open Deploy Folder in Terminal
- In the terminal, run:
Orixen will:
- Generate the TypeScript deploy code
- Create Terraform configurations for Lambda and API Gateway
- Terraform will deploy and display your API endpoint URL
Step 6: Test Your API
Once deployed, test your API using curl or your browser:
# With name parameter
curl "https://<your API endpoint>/hello?name=Orixen"
# Response: "Hello Orixen"
# Without name parameter (uses default)
curl "https://<your API endpoint>/hello"
# Response: "Hello World"
Your Workflow
Your completed workflow should look like this:
+---------+ +----------+ +----------+
| API |---->| Function |---->| Response |
| /hello | | Lambda | | |
+---------+ +----------+ +----------+
7. Coding with AI Agents
Now we will change the Greet Function using AI Agents to help you code your functions. AI agents work especially well with small and isolated contexts, like serverless functions. Orixen automatically provides the function code context to the AI agent, so it can help you code faster.
- Open your Project Settings in the Menu
- Set up the CLI config for your preferred AI agent (e.g., Claude, Codex, etc.)
- Double click the "Greet Function" block
- Click "Code with Agent"
- Write a spec for the function like this:
- Click "Start Agent"
8. Testing Locally
Orixen allows you to test your functions locally before deploying.
- Double click the "Greet Function" block
- Click "Run"
- Provide a sample input. Click on "New" on the left side. Paste the sample below and give it a name.
{ "text": "Team Contact Information For any questions regarding the upcoming product launch, please reach out to the appropriate team member below. For marketing inquiries and press releases, contact Sarah Mitchell at sarah.mitchell@company.com. She handles all external communications and media requests. Technical support and bug reports should be directed to our engineering lead, James Chen, at j.chen@techsupport.org. He typically responds within 24 hours on business days. If you have billing questions or need to update your subscription, our finance department can assist you. Send an email to billing@acme-services.net and include your account number in the subject line for faster processing. We look forward to hearing from you!" } - Click "Run" and check logs.
Next Steps
Congratulations! You have built and deployed your first API with Orixen. Here are some ideas to explore next:
Explore each block in more detail in the Blocks Overview documentation.