CLOUDYNIC API DOCUMENTATION

PRO API Reference

Complete guide to using the Cloudynic API

Quick Start

Base URL

https://api.cloudynic.com

PRO API Endpoint

https://api.cloudynic.com/r?prompt=hello&u=username&p=password

Response Type

Server-Sent Events (SSE) - real-time streaming text responses

Parameters

prompt

Your question or request to the AI

Type: string

Required: yes

u (username)

Your PRO account username

Type: string

Required: yes

p (password)

Your PRO account password

Type: string

Required: yes

voice (optional)

Generate audio response from the AI text (PRO only)

Type: boolean

Required: no

Example: &voice=true

PRO Features

Unlimited Requests

No rate limiting, unlimited requests per minute

Unlimited Tokens

No token limits per request or per day

Stream API

Real-time streaming responses with SSE

30-Day Access

Full PRO access for 30 days from purchase

Voice Generation

Convert AI responses to audio with ?voice=true parameter

Code Examples

cURL

curl -X GET "https://api.cloudynic.com/r?prompt=What%20is%20AI%3F&u=your_username&p=your_password"

HTML + JavaScript

<!DOCTYPE html>
<html>
<head>
    <title>Cloudynic API Demo</title>
    <style>
        body { font-family: monospace; max-width: 800px; margin: 50px auto; }
        input { width: 100%; padding: 10px; }
        button { padding: 10px 20px; margin-top: 10px; }
        #response { margin-top: 20px; padding: 10px; border: 1px solid #ccc; }
    </style>
</head>
<body>
    <h1>Cloudynic API - PRO</h1>
    <input type="text" id="prompt" placeholder="Ask...">
    <button onclick="askAI()">Send</button>
    <div id="response"></div>
    <script>
        const U = 'username', P = 'password'
        async function askAI() {
            const p = document.getElementById('prompt').value
            const url = `https://api.cloudynic.com/r?prompt=${encodeURIComponent(p)}&u=${U}&p=${P}`
            const r = await fetch(url)
            const reader = r.body.getReader()
            const decoder = new TextDecoder()
            let res = ''
            while (true) {
                const {done, value} = await reader.read()
                if (done) break
                res += decoder.decode(value, {stream: true})
                document.getElementById('response').innerHTML = res
            }
        }
    </script>
</body>
</html>

Voice Generation (HTML)

<!DOCTYPE html>
<html>
<head>
    <title>Cloudynic Voice</title>
</head>
<body>
    <h1>Voice Generation</h1>
    <input type="text" id="prompt" value="Tell me a fact">
    <button onclick="generateVoice()">Generate</button>
    <div id="response"></div>
    <script>
        const U='user', P='pass'
        async function generateVoice() {
            const p = document.getElementById('prompt').value
            const url = `https://api.cloudynic.com/r?prompt=${encodeURIComponent(p)}&u=${U}&p=${P}&voice=true`
            const r = await fetch(url)
            const blob = await r.blob()
            const url2 = URL.createObjectURL(blob)
            document.getElementById('response').innerHTML = `<audio controls src="${url2}"></audio>`
        }
    </script>
</body>
</html>

Python (Text)

import requests

USERNAME = 'your_username'
PASSWORD = 'your_password'
BASE_URL = 'https://api.cloudynic.com'

def ask_ai(prompt):
    url = f'{BASE_URL}/r'
    params = {
        'prompt': prompt,
        'u': USERNAME,
        'p': PASSWORD
    }
    response = requests.get(url, params=params, stream=True)
    if response.status_code == 200:
        for chunk in response.iter_content(decode_unicode=True):
            if chunk:
                print(chunk, end='', flush=True)
    else:
        print(f'Error: {response.status_code}')

ask_ai('What is AI?')

Need Help?

Check the setup page for detailed implementation guides