1. Chart Analysis
Returning.AI
  • Getting Started
  • Users
    • User directory and provisioning
    • Get Users with Filters
      POST
    • Create New User
      POST
    • Get User Data
      POST
    • Manage User Account
      POST
    • Get User Milestones
      POST
    • Update User Data, Identifier, And Roles
      POST
    • Update User XP and Currency
      POST
  • Messaging
    • Agent messaging workflow
    • Get Messages
      GET
    • Send Message
      POST
    • Reply Message
      POST
    • React Message
      POST
    • Upload message images
      POST
  • Gamification
    • Leaderboards
      • Leaderboards
      • List leaderboards with pagination
      • Create a new leaderboard
      • Update an existing leaderboard
      • Get a single leaderboard by ID
      • Delete a leaderboard
    • Streaks & Mini Games
      • Mini-game State and History
      • List user streak logs
      • List mini-game logs by user email
      • Get current mini-game and streak state
      • Update user spin-wheel information
    • Referral
      • Referral Program Integration
      • Get referral programs
      • Get user's referral summary
    • Rolling Data
      • Get Daily Calculation Data
      • Get Rolling Calculation Data
    • Match Predictions
    • Get tier configuration
      GET
    • Get daily user XP and coin changes
      POST
    • Search user gamification logs
      POST
    • Get user activity stats
      POST
  • Rewards & Redemptions
    • Store catalog to redemptions
    • Update redemption order status or refund
    • List redemption orders by user email
    • List redemption statuses
    • Get redemption status by ID
    • List redemption orders by community
    • Create redemption order status
    • Get redemption order status history
  • Chart Analysis
    • Create Analysis
      POST
    • Get Analysis
      GET
    • Update Analysis
      PATCH
    • Delete Analysis
      DELETE
    • List Analyses
      GET
    • Append Drawings
      POST
  • Bulk Operations
    • Bulk user updates
    • List bulk update jobs
    • Get bulk update job status
    • Get bulk update job details
    • Bulk update users from CSV
    • Bulk update premium currency from CSV
  • Channels
    • Iframe
    • List integration channels
  • Events
    • Outgoing webhooks
      • Encryption
      • User Joins Server
      • User Visits server
      • New Message Posted Anywhere
      • New Message Posted To channel
      • Purchased Store Item
    • Incoming webhooks
      • API Keys & Encryption
      • Send message into channels
      • Update Custom User Fields
      • Update In-game currency
  • Widgets
    • Authenticated Widgets
    • Public widgets
    • Channels
    • Leaderboard
    • Milestone
    • Socials
    • Store
  • Community Analytics
    • Get Loyalty Overview
    • Get Phone Verification Contacts
  • Store
    • Store catalog
    • Purchase History
      • Update redemption instructions or voucher details
    • Categories
      • List Store categories
      • Create Store category
      • Get Store category by ID
      • Update Store category
      • Delete Store category
    • Products
      • List products
      • Update products in bulk
      • Create products in bulk
      • Create product with vouchers
      • Read product
      • Update product and append vouchers
      • Delete product
    • Redemption-transaction
      • Get redemption transaction detail
    • Get Store configuration
    • Update Store configuration
  • Community
    • Community directory and appearance
    • Appearance
      • Update community theme colors
      • Update community bot profile
      • Update community URL metadata
      • Update community name and URL
    • Community Users
      • Get community users
      • Get user
    • Create community
  • API Keys
    • API key lifecycle
    • Community API Keys
      • Create API key
      • Read API keys
      • Delete API key
      • Update API key
    • User API Keys
      • List user API keys
      • Create user API key
      • Update user API key
      • Delete user API key
      • Get current API key information
  • User Fields
    • User field definitions and history
    • User Field History
      • Get all user field histories in a community
      • Get user field histories for a specific field
      • Get user field histories for a specific user
      • Get user field histories of specific user field and user
      • Update A User Field Value
      • Deprecated Field-First History Write
      • Deprecated Field-First History Read
    • Get A User Field Definition
    • Update A User Field Definition
    • Create A User Field Definition
    • Delete A User Field Definition
    • List User Field Definitions
  • Legacy
    • Servers
      • Create server
      • List servers
      • Update server metadata
    • Bulk Operations
      • Bulk import users from CSV
    • Authentication
      • Secure Auth
      • Register user with password
      • Verify user email
      • Log in user with password
    • Badges
      • List badges
      • Create badge
      • Update badge
      • Delete badge
      • Remove badge from user
      • Award badge to user
    • Messaging
    • Roles & Permissions
      • List server roles
      • Create role
      • Update role
      • Delete role
      • List user roles
      • Add role to user
      • Remove role from user
    • Users
      • Get user
      • Upload user avatar
    • Channels
      • Create channel
      • Update channel
      • Delete channel
    • API Keys
      • List integration API keys
      • Create integration API key
      • Delete integration API key
      • Update integration API key
  1. Chart Analysis

Create Analysis

POST
/v1/analysis/{communityId}/channels/{channelId}

What this endpoint does#

Creates a structured chart analysis in one channel. Community API-key callers must send sender (member email).
The channel must have chartsEnabled: true. A normal text channel returns 400 Channel does not support analysis posts (chartsEnabled is false) after the body validates.
INFO
Safer path
List analyses first. Do not POST a complete body at a live text channel expecting a card. Missing sender and missing metadata fail validation before the chartsEnabled check.

Quick start#

Required permission: sendMessage. Optional idempotencyKey and drawings are documented on the schema on this page.

Authentication and permission#

Bearer community API key with sendMessage. Keep the key server-side. sender must be a member email that exists in the community.

Complete examples#

Missing sender / incomplete metadata (400). Create Analysis Request Validation validation error. Typical detail: metadata.direction must be BULLISH or BEARISH; entryPlacement ABOVE_CURRENT or BELOW_CURRENT; expiry, preferenceText, symbol, levels required; timeframe one of M1, M5, M15, M30, H1, H2, H4, D, W, M.
Unknown sender (404). User not found.
Text channel (400). After a complete body: Channel does not support analysis posts (chartsEnabled is false). Reproduced on a channel whose topic includes "analysis". GET /v1/channels still omits chartsEnabled.
A 201/200 create body is not documented. No chart-enabled channel was available on the throwaway community used for this pass.
Treat emails and symbols as synthetic.

Success and readback#

When a chart-enabled channel accepts the POST, read back with Get Analysis and List Analyses. Save analysisId from the create body when present.

Errors and recovery#

StatusWhenRecovery
400 validationMissing metadata/levels/senderSend the required fields. Direction in create body is uppercase.
404 User not foundsender is not a memberUse an existing member email.
400 chartsEnabled is falseChannel is not chart-enabledUse a chart-enabled channel. GET /v1/channels will not tell you.
401Missing or invalid tokenAdd a key with sendMessage.

Retry safety#

WARNING
Exact retry
If a timeout hides a successful create, list the channel before posting again. Use idempotencyKey when the schema supports it. Duplicate POSTs can create additional analyses.

Gotchas#

List filter direction=bullish is lowercase; create metadata.direction is BULLISH.
GET /v1/channels omits chartsEnabled.

Next steps#

List Analyses
Confirm whether the channel already has analyses before creating another.

Request

Authorization
JWT Bearer
Add the parameter
Authorization
to Headers
Example:
Authorization: ********************
or
Path Params

Body Params application/jsonRequired

Examples

Responses

🟢200OK
application/json
Analysis created successfully
Bodyapplication/json

🟠400Bad Request
🟠401Unauthorized
🟠403Forbidden
🟠404Record Not Found
🔴500Server Error
Request Request Example
Shell
JavaScript
Java
Swift
curl --location 'https://adss-integration.returning.ai/apis/v1/analysis/6502c9e514a3e564c5c09c0a/channels/656966caae59563fb291b324' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "sender": "pangray2025+t5@gmail.com",
    "metadata": {
        "direction": "BULLISH",
        "entryPlacement": "BELOW_CURRENT",
        "expiry": {
            "type": "HOURS",
            "hours": 24
        },
        "title": "GBPUSD Bullish Bounce from Support",
        "preferenceText": "Price bounced from [[support_zone:demand zone]]. Entry above [[entry_line:breakout level]] with target at [[target:resistance]].",
        "alternativeText": "If price breaks below support, analysis invalidated",
        "comments": "Watch for volume confirmation",
        "timeframe": "H1",
        "symbol": "GBP/USD"
    },
    "levels": {
        "pivot": {
            "price": 1.345,
            "clientObjectId": "pivot_main",
            "time": "2026-01-08T12:00:00Z"
        },
        "resistance": {
            "price": 1.35,
            "clientObjectId": "res_1",
            "time": "2026-01-08T14:00:00Z"
        },
        "support": {
            "price": 1.341,
            "clientObjectId": "sup_1",
            "time": "2026-01-08T10:00:00Z"
        }
    },
    "drawings": [
        {
            "type": "RECTANGLE",
            "clientObjectId": "support_zone",
            "points": [
                {
                    "time": "2026-01-08T00:00:00Z",
                    "price": 1.338
                },
                {
                    "time": "2026-01-09T00:00:00Z",
                    "price": 1.347
                }
            ],
            "style": {
                "fillColor": "#00FF33",
                "borderColor": "#00FF00",
                "lineWidth": 2
            }
        },
        {
            "type": "LINE",
            "clientObjectId": "entry_line",
            "points": [
                {
                    "time": "2026-01-08T00:00:00Z",
                    "price": 1.3485
                },
                {
                    "time": "2026-01-09T00:00:00Z",
                    "price": 1.3505
                }
            ],
            "startHead": "NONE",
            "endHead": "ARROW",
            "style": {
                "color": "#0000FF",
                "lineWidth": 2,
                "lineStyle": "DASHED"
            }
        },
        {
            "type": "HORIZONTAL_LINE",
            "clientObjectId": "target",
            "points": [
                {
                    "time": "2026-01-08T10:00:00Z",
                    "price": 1.355
                }
            ],
            "style": {
                "color": "#FF0000",
                "lineWidth": 2,
                "lineStyle": "SOLID"
            }
        }
    ],
    "idempotencyKey": "analysis_20250109_001"
}'
Response Response Example
200 - Success Example
{
    "status": "success",
    "message": "Analysis created successfully",
    "data": {
        "analysisId": "507f1f77bcf86cd799439022",
        "objectIdMap": {
            "pivot_main": "60d5ec49f1b2c8b1f8e4c8a1:8",
            "res_1": "60d5ec49f1b2c8b1f8e4c8a1:7",
            "sup_1": "60d5ec49f1b2c8b1f8e4c8a1:0",
            "res_int": "60d5ec49f1b2c8b1f8e4c8a1:5",
            "sup_int": "60d5ec49f1b2c8b1f8e4c8a1:2",
            "support_zone": "60d5ec49f1b2c8b1f8e4c8a2",
            "entry_line": "60d5ec49f1b2c8b1f8e4c8a3",
            "target": "60d5ec49f1b2c8b1f8e4c8a4"
        }
    }
}
Modified at 2026-08-19 18:37:28
Previous
Get redemption order status history
Next
Get Analysis
Built with