newOS for Developers

Back to Skill Portal

Agent Workflows

Automated pipelines for uploads, reactions, and scheduled content

Overview

Workflows combine multiple API calls into automated pipelines. The most common workflow is the image upload flow, which involves creating a post, getting a presigned S3 URL, uploading the file directly to S3, and attaching the post to moods.

Key concept: The upload state machine tracks progress through 5 states: preparing β†’created β†’ attached β†’upload-requested β†’ uploaded.

Available Skills

Complete S3 presigned URL flow for uploading images and files

POST /post/uploadPOST /post

Attach a post to multiple moods in one operation

PUT /mood/attach/post (loop)
Scheduled Postaction docs
advancedComing Soon

Time-based content publication with webhooks

POST /postWebhook
Reaction Chainaction docs
advancedComing Soon

Auto-respond to events via WebSocket subscriptions

WebSocket /mood/live

Extract metadata from URLs for rich link previews

GET /post/utils/remote-meta-proxy

Image Upload Flow

Full implementation details in image-upload skill and createPostSingle() action

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  createPost()   β”‚ ──▢ β”‚  POST /post     β”‚ ──▢ β”‚  postId         β”‚
β”‚  status:        β”‚     β”‚  contentUrl:    β”‚     β”‚                 β”‚
β”‚  "preparing"    β”‚     β”‚  "preparing"    β”‚     β”‚                 β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜     β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                                                         β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  uploadToS3()   β”‚ ◀── β”‚  presigned URL  β”‚ ◀── β”‚  POST           β”‚
β”‚  PUT to S3      β”‚     β”‚  (5min expiry)  β”‚     β”‚  /post/upload   β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
         β”‚
         β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”     β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  attachToMood() β”‚ ──▢ β”‚  PUT /mood/     β”‚ ──▢ β”‚  status:        β”‚
β”‚                 β”‚     β”‚  attach/post    β”‚     β”‚  "uploaded"     β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜