UGCDocumentation

Automation actions (7)

Campaign discovery, funding, slots, username check, and crypto deposit addresses

Updated October 3, 2026
GET/api/automation/actions/usernames/check/:username
Required

Campaign discovery, funding, slots, username check, and crypto deposit addresses

Rate Limit

This endpoint is limited to 100 requests per 1 minute per API key.

Rate limit headers are included in all responses: X-RateLimit-Limit, X-RateLimit-Remaining

Interactive API PlaygroundTest this endpoint directly from your browser

Credentials

Your API key is never stored and only used for this request

curl -X GET https://api.ugc.africa/api/automation/actions/usernames/check/:username \
  -H "Authorization: Bearer YOUR_API_KEY"
Coming soon

SDK examples (coming soon)

JavaScript
// Official Node SDK - coming soon. Use REST (see Getting Started) or fetch() examples.
// Planned: npm install @UGC/node

Official @UGC/* client libraries are on the roadmap. Integrate with the REST API and webhooks today. SDK pages · Email notify

Success

JSON
{
  "id": "..."
}
curl
curl -X POST https://api.ugc.africa/automation/actions/crypto/wallets/deposit-address \
  -H "Authorization: Bearer UGAU_live_xxx" \
  -H "Content-Type: application/json" \
  -d '{ "currency": "USDT", "network": "TRC20" }'

All routes are under /api/automation/actions and require Bearer (Automation connection key or OAuth access token). Send an Idempotency-Key header on POSTs for safe retries (24h replay window).

#Method & pathPurpose
1GET /api/automation/actions/usernames/check/:usernameCheck username availability
2POST /api/automation/actions/crypto/wallets/deposit-addressGenerate a crypto deposit address
3GET /api/automation/actions/campaignsList my campaigns (?status= filter)
4POST /api/automation/actions/campaignsCreate a DRAFT campaign
5GET /api/automation/actions/campaigns/:idGet a campaign I own
6POST /api/automation/actions/campaigns/:id/fundFund a campaign
7GET /api/automation/actions/campaigns/:id/slotsList a campaign's creator slots

Generate a crypto deposit address

Create a campaign

Key fields: title, payoutType (FLAT | CPM_SOCIAL | CPM_STREAMING - not CPM), advertiserCpmRate, and totalBudget are required. The rate field is advertiserCpmRate. Channels are targetPlatforms (slugs such as whatsapp_status and snapchat). assets are URLs (no upload tool). Optional targeting (targetNiches, countryAllowlist, minCreatorLevel, minKycTier) and creative fields (captionTemplate, requiredHashtags) follow the same create schema as MCP campaign_create. The campaign is created DRAFT and unfunded - fund it next. OAuth callers need campaign:write to create and campaign:fund to fund; API keys and portal JWTs are not filtered by that scope ladder. Confirm before any funding call.

Fund a campaign

method is one of checkout (returns a checkout URL), payment_link (returns a shareable funding link), or wallet (debits the platform wallet immediately). amount defaults to the campaign's totalBudget on first funding. The campaign_funded trigger fires once the payment settles.

List a campaign's slots

Returns each slot's status, platform, postUrl, totalViews, and timestamps - only the campaign owner can query this.

Common Errors

400INVALID_CURRENCY

Invalid Currency Code

The currency code provided is not supported.

Example Response
JSON
{
  "success": false,
  "error": {
    "code": "INVALID_CURRENCY",
    "message": "Currency code \"XYZ\" is not supported",
    "supportedCurrencies": [
      "USD",
      "EUR",
      "GBP",
      "GHS",
      "NGN"
    ]
  }
}

Solution: Use a valid ISO 4217 currency code. See our list of supported currencies.

400INSUFFICIENT_BALANCE

Insufficient Wallet Balance

The wallet does not have enough balance to complete this transaction.

Example Response
JSON
{
  "success": false,
  "error": {
    "code": "INSUFFICIENT_BALANCE",
    "message": "Insufficient balance in USD wallet",
    "required": 5000,
    "available": 2500
  }
}

Solution: Add funds to your wallet or use a different payment method.

401UNAUTHORIZED

Authentication Required

The request requires authentication but none was provided.

Example Response
JSON
{
  "success": false,
  "error": {
    "code": "UNAUTHORIZED",
    "message": "Invalid or expired authentication token"
  }
}

Solution: Include a valid API key or JWT token in the Authorization header.

429RATE_LIMIT_EXCEEDED

Rate Limit Exceeded

Too many requests have been made in a short period.

Example Response
JSON
{
  "success": false,
  "error": {
    "code": "RATE_LIMIT_EXCEEDED",
    "message": "Rate limit exceeded. Try again in 60 seconds",
    "retryAfter": 60
  }
}

Solution: Wait for the specified retry period before making another request. Consider implementing exponential backoff.

Did this solve your problem?