Slot Machine SimulatorSlot Machine Simulator API

OnlineCredit Usage:1 per callRefreshed 1 month ago
avg: 167ms|p50: 161ms|p75: 171ms|p90: 183ms|p99: 207ms

Overview

To use Slot Machine Simulator, you need an API key. You can get one by creating a free account and visiting your dashboard.

GET Endpoint

URL
https://api.apiverve.com/v1/slotmachine

Example

How to call the Slot Machine Simulator API in different programming languages.

cURL Request
curl -X GET \
  "https://api.apiverve.com/v1/slotmachine?spins=5&reels=3&bet=1" \
  -H "X-API-Key: your_api_key_here"
JavaScript (Fetch API)
const response = await fetch('https://api.apiverve.com/v1/slotmachine?spins=5&reels=3&bet=1', {
  method: 'GET',
  headers: {
    'X-API-Key': 'your_api_key_here',
    'Content-Type': 'application/json'
  }
});

const data = await response.json();
console.log(data);
Python (Requests)
import requests

headers = {
    'X-API-Key': 'your_api_key_here',
    'Content-Type': 'application/json'
}

response = requests.get('https://api.apiverve.com/v1/slotmachine?spins=5&reels=3&bet=1', headers=headers)

data = response.json()
print(data)
Go (net/http)
package main

import (
    "fmt"
    "io"
    "net/http"

)

func main() {
    req, _ := http.NewRequest("GET", "https://api.apiverve.com/v1/slotmachine?spins=5&reels=3&bet=1", nil)

    req.Header.Set("X-API-Key", "your_api_key_here")
    req.Header.Set("Content-Type", "application/json")

    client := &http.Client{}
    resp, err := client.Do(req)
    if err != nil {
        panic(err)
    }
    defer resp.Body.Close()

    body, _ := io.ReadAll(resp.Body)
    fmt.Println(string(body))
}
Example Response
{
  "status": "ok",
  "error": null,
  "data": {
    "total_spins": 5,
    "num_reels": 3,
    "bet_per_spin": 1,
    "spins": [
      {
        "spin_number": 1,
        "reels": [
          {
            "symbol": "🍋",
            "name": "Lemon"
          },
          {
            "symbol": "🍒",
            "name": "Cherry"
          },
          {
            "symbol": "🍒",
            "name": "Cherry"
          }
        ],
        "bet": 1,
        "payout": 0,
        "win_type": "none",
        "is_win": false
      },
      {
        "spin_number": 2,
        "reels": [
          {
            "symbol": "⭐",
            "name": "Star"
          },
          {
            "symbol": "🍋",
            "name": "Lemon"
          },
          {
            "symbol": "⭐",
            "name": "Star"
          }
        ],
        "bet": 1,
        "payout": 0,
        "win_type": "none",
        "is_win": false
      },
      {
        "spin_number": 3,
        "reels": [
          {
            "symbol": "🍊",
            "name": "Orange"
          },
          {
            "symbol": "🍇",
            "name": "Grape"
          },
          {
            "symbol": "🍋",
            "name": "Lemon"
          }
        ],
        "bet": 1,
        "payout": 0,
        "win_type": "none",
        "is_win": false
      },
      {
        "spin_number": 4,
        "reels": [
          {
            "symbol": "🍒",
            "name": "Cherry"
          },
          {
            "symbol": "⭐",
            "name": "Star"
          },
          {
            "symbol": "🔔",
            "name": "Bell"
          }
        ],
        "bet": 1,
        "payout": 0,
        "win_type": "none",
        "is_win": false
      },
      {
        "spin_number": 5,
        "reels": [
          {
            "symbol": "🍒",
            "name": "Cherry"
          },
          {
            "symbol": "🍒",
            "name": "Cherry"
          },
          {
            "symbol": "7️⃣",
            "name": "Seven"
          }
        ],
        "bet": 1,
        "payout": 0.5,
        "win_type": "small",
        "is_win": true
      }
    ],
    "total_bet": 5,
    "total_winnings": 0.5,
    "net_profit": -4.5,
    "wins": 1,
    "losses": 4,
    "win_percentage": 20,
    "available_symbols": [
      {
        "symbol": "🍒",
        "name": "Cherry",
        "payout_multiplier": 2
      },
      {
        "symbol": "🍋",
        "name": "Lemon",
        "payout_multiplier": 3
      },
      {
        "symbol": "🍊",
        "name": "Orange",
        "payout_multiplier": 5
      },
      {
        "symbol": "🍇",
        "name": "Grape",
        "payout_multiplier": 10
      },
      {
        "symbol": "🔔",
        "name": "Bell",
        "payout_multiplier": 20
      },
      {
        "symbol": "⭐",
        "name": "Star",
        "payout_multiplier": 50
      },
      {
        "symbol": "💎",
        "name": "Diamond",
        "payout_multiplier": 100
      },
      {
        "symbol": "7️⃣",
        "name": "Seven",
        "payout_multiplier": 200
      }
    ]
  }
}

Authentication

The Slot Machine Simulator API requires authentication via API key. Include your API key in the request header:

Required Header
X-API-Key: your_api_key_here

Learn more about authentication →

Interactive API Playground

Test the Slot Machine Simulator API directly in your browser with live requests and responses.

Parameters

The following parameters are available for the Slot Machine Simulator API:

Spin Slot Machine

ParameterTypeRequiredDescriptionDefaultExample
spinsintegeroptional
Number of spins to simulate
Range: 1 - 5
15
reelsintegeroptional
Number of reels
Range: 3 - 5
33
betnumberoptional
Bet amount per spin
Range: 0 - 1000
11

Response

The Slot Machine Simulator API returns responses in JSON, XML, YAML, and CSV formats. The JSON response is shown in the Example section above; alternative formats below.

Other Response Formats

XML Response
200 OK
<?xml version="1.0" encoding="UTF-8"?>
<response>
  <status>ok</status>
  <error xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
  <data>
    <total_spins>5</total_spins>
    <num_reels>3</num_reels>
    <bet_per_spin>1</bet_per_spin>
    <spins>
      <spin>
        <spin_number>1</spin_number>
        <reels>
          <reel>
            <symbol>🍋</symbol>
            <name>Lemon</name>
          </reel>
          <reel>
            <symbol>🍒</symbol>
            <name>Cherry</name>
          </reel>
          <reel>
            <symbol>🍒</symbol>
            <name>Cherry</name>
          </reel>
        </reels>
        <bet>1</bet>
        <payout>0</payout>
        <win_type>none</win_type>
        <is_win>false</is_win>
      </spin>
      <spin>
        <spin_number>2</spin_number>
        <reels>
          <reel>
            <symbol>⭐</symbol>
            <name>Star</name>
          </reel>
          <reel>
            <symbol>🍋</symbol>
            <name>Lemon</name>
          </reel>
          <reel>
            <symbol>⭐</symbol>
            <name>Star</name>
          </reel>
        </reels>
        <bet>1</bet>
        <payout>0</payout>
        <win_type>none</win_type>
        <is_win>false</is_win>
      </spin>
      <spin>
        <spin_number>3</spin_number>
        <reels>
          <reel>
            <symbol>🍊</symbol>
            <name>Orange</name>
          </reel>
          <reel>
            <symbol>🍇</symbol>
            <name>Grape</name>
          </reel>
          <reel>
            <symbol>🍋</symbol>
            <name>Lemon</name>
          </reel>
        </reels>
        <bet>1</bet>
        <payout>0</payout>
        <win_type>none</win_type>
        <is_win>false</is_win>
      </spin>
      <spin>
        <spin_number>4</spin_number>
        <reels>
          <reel>
            <symbol>🍒</symbol>
            <name>Cherry</name>
          </reel>
          <reel>
            <symbol>⭐</symbol>
            <name>Star</name>
          </reel>
          <reel>
            <symbol>🔔</symbol>
            <name>Bell</name>
          </reel>
        </reels>
        <bet>1</bet>
        <payout>0</payout>
        <win_type>none</win_type>
        <is_win>false</is_win>
      </spin>
      <spin>
        <spin_number>5</spin_number>
        <reels>
          <reel>
            <symbol>🍒</symbol>
            <name>Cherry</name>
          </reel>
          <reel>
            <symbol>🍒</symbol>
            <name>Cherry</name>
          </reel>
          <reel>
            <symbol>7️⃣</symbol>
            <name>Seven</name>
          </reel>
        </reels>
        <bet>1</bet>
        <payout>0.5</payout>
        <win_type>small</win_type>
        <is_win>true</is_win>
      </spin>
    </spins>
    <total_bet>5</total_bet>
    <total_winnings>0.5</total_winnings>
    <net_profit>-4.5</net_profit>
    <wins>1</wins>
    <losses>4</losses>
    <win_percentage>20</win_percentage>
    <available_symbols>
      <available_symbol>
        <symbol>🍒</symbol>
        <name>Cherry</name>
        <payout_multiplier>2</payout_multiplier>
      </available_symbol>
      <available_symbol>
        <symbol>🍋</symbol>
        <name>Lemon</name>
        <payout_multiplier>3</payout_multiplier>
      </available_symbol>
      <available_symbol>
        <symbol>🍊</symbol>
        <name>Orange</name>
        <payout_multiplier>5</payout_multiplier>
      </available_symbol>
      <available_symbol>
        <symbol>🍇</symbol>
        <name>Grape</name>
        <payout_multiplier>10</payout_multiplier>
      </available_symbol>
      <available_symbol>
        <symbol>🔔</symbol>
        <name>Bell</name>
        <payout_multiplier>20</payout_multiplier>
      </available_symbol>
      <available_symbol>
        <symbol>⭐</symbol>
        <name>Star</name>
        <payout_multiplier>50</payout_multiplier>
      </available_symbol>
      <available_symbol>
        <symbol>💎</symbol>
        <name>Diamond</name>
        <payout_multiplier>100</payout_multiplier>
      </available_symbol>
      <available_symbol>
        <symbol>7️⃣</symbol>
        <name>Seven</name>
        <payout_multiplier>200</payout_multiplier>
      </available_symbol>
    </available_symbols>
  </data>
</response>
YAML Response
200 OK
status: ok
error: null
data:
  total_spins: 5
  num_reels: 3
  bet_per_spin: 1
  spins:
    - spin_number: 1
      reels:
        - symbol: 🍋
          name: Lemon
        - symbol: 🍒
          name: Cherry
        - symbol: 🍒
          name: Cherry
      bet: 1
      payout: 0
      win_type: none
      is_win: false
    - spin_number: 2
      reels:
        - symbol: ⭐
          name: Star
        - symbol: 🍋
          name: Lemon
        - symbol: ⭐
          name: Star
      bet: 1
      payout: 0
      win_type: none
      is_win: false
    - spin_number: 3
      reels:
        - symbol: 🍊
          name: Orange
        - symbol: 🍇
          name: Grape
        - symbol: 🍋
          name: Lemon
      bet: 1
      payout: 0
      win_type: none
      is_win: false
    - spin_number: 4
      reels:
        - symbol: 🍒
          name: Cherry
        - symbol: ⭐
          name: Star
        - symbol: 🔔
          name: Bell
      bet: 1
      payout: 0
      win_type: none
      is_win: false
    - spin_number: 5
      reels:
        - symbol: 🍒
          name: Cherry
        - symbol: 🍒
          name: Cherry
        - symbol: 7️⃣
          name: Seven
      bet: 1
      payout: 0.5
      win_type: small
      is_win: true
  total_bet: 5
  total_winnings: 0.5
  net_profit: -4.5
  wins: 1
  losses: 4
  win_percentage: 20
  available_symbols:
    - symbol: 🍒
      name: Cherry
      payout_multiplier: 2
    - symbol: 🍋
      name: Lemon
      payout_multiplier: 3
    - symbol: 🍊
      name: Orange
      payout_multiplier: 5
    - symbol: 🍇
      name: Grape
      payout_multiplier: 10
    - symbol: 🔔
      name: Bell
      payout_multiplier: 20
    - symbol: ⭐
      name: Star
      payout_multiplier: 50
    - symbol: 💎
      name: Diamond
      payout_multiplier: 100
    - symbol: 7️⃣
      name: Seven
      payout_multiplier: 200
CSV Response
200 OK
keyvalue
total_spins5
num_reels3
bet_per_spin1
spins[{spin_number:1,reels:[{symbol:🍋,name:Lemon},{symbol:🍒,name:Cherry},{symbol:🍒,name:Cherry}],bet:1,payout:0,win_type:none,is_win:false},{spin_number:2,reels:[{symbol:⭐,name:Star},{symbol:🍋,name:Lemon},{symbol:⭐,name:Star}],bet:1,payout:0,win_type:none,is_win:false},{spin_number:3,reels:[{symbol:🍊,name:Orange},{symbol:🍇,name:Grape},{symbol:🍋,name:Lemon}],bet:1,payout:0,win_type:none,is_win:false},{spin_number:4,reels:[{symbol:🍒,name:Cherry},{symbol:⭐,name:Star},{symbol:🔔,name:Bell}],bet:1,payout:0,win_type:none,is_win:false},{spin_number:5,reels:[{symbol:🍒,name:Cherry},{symbol:🍒,name:Cherry},{symbol:7️⃣,name:Seven}],bet:1,payout:0.5,win_type:small,is_win:true}]
total_bet5
total_winnings0.5
net_profit-4.5
wins1
losses4
win_percentage20
available_symbols[{symbol:🍒,name:Cherry,payout_multiplier:2},{symbol:🍋,name:Lemon,payout_multiplier:3},{symbol:🍊,name:Orange,payout_multiplier:5},{symbol:🍇,name:Grape,payout_multiplier:10},{symbol:🔔,name:Bell,payout_multiplier:20},{symbol:⭐,name:Star,payout_multiplier:50},{symbol:💎,name:Diamond,payout_multiplier:100},{symbol:7️⃣,name:Seven,payout_multiplier:200}]

Response Structure

All API responses follow a consistent structure with the following fields:

FieldTypeDescriptionExample
statusstringIndicates whether the request was successful ("ok") or failed ("error")ok
errorstring | nullContains error message if status is "error", otherwise nullnull
dataobject | nullContains the API response data if successful, otherwise null{...}

Learn more about response formats →

Response Data Fields

When the request is successful, the data object contains the following fields:

Response fields marked with Premium are available exclusively on paid plans.View pricing
FieldTypeSample ValueDescription
total_spinsnumber5
Total number of spins simulated in session
num_reelsnumber3
Number of reels used per spin
bet_per_spinnumber1
Bet amount placed per individual spin
[ ] Array items:array[5]Array of objects
Array containing detailed information for each spin
spin_numbernumber1
Sequential number identifying this spin
[ ] Array items:array[3]Array of objects
Array of reel results for this spin
symbolstring"🍋"
Emoji symbol displayed on the reel
namestring"Lemon"
Human-readable name of reel symbol
betnumber1
Bet amount wagered for this spin
payoutPremiumnumber0
Monetary payout amount won from spin
win_typePremiumstring"none"
Classification of win result for spin
is_winPremiumbooleanfalse
Whether spin resulted in winning combination
total_betnumber5
Total amount wagered across all spins
total_winningsPremiumnumber0.5
Total monetary winnings from all spins
net_profitPremiumnumber-4.5
Calculated profit or loss after all spins
winsPremiumnumber1
Count of successful winning spins
lossesPremiumnumber4
Count of losing spins in session
win_percentagePremiumnumber20
Percentage of spins that resulted in wins
[ ] Array items:array[8]Array of objects
Array of all possible symbols used
symbolstring"🍒"
Emoji symbol available in slot machine

Headers

Only X-API-Key is required. Optional headers include Accept for response format negotiation (JSON, XML, or YAML), User-Agent, and X-Request-ID for request tracing. See all request headers →

GraphQL AccessALPHA

Access Slot Machine Simulator through GraphQL to combine it with other API calls in a single request. Query only the slot machine simulator data you need with precise field selection, and orchestrate complex data fetching workflows.

Test Slot Machine Simulator in the GraphQL Explorer to confirm availability and experiment with queries.

Credit Cost: Each API called in your GraphQL query consumes its standard credit cost.

GraphQL Endpoint
POST https://api.apiverve.com/v1/graphql
GraphQL Query Example
query {
  slotmachine(
    input: {
      spins: 5
      reels: 3
      bet: 1
    }
  ) {
    total_spins
    num_reels
    bet_per_spin
    spins
    total_bet
    total_winnings
    net_profit
    wins
    losses
    win_percentage
    available_symbols
  }
}

Note: Authentication is handled via the x-api-key header in your GraphQL request, not as a query parameter.

CORS Support

The Slot Machine Simulator API accepts cross-origin requests from any origin, so it can be called directly from browser-based applications without a proxy. See CORS support →

Rate Limiting

Slot Machine Simulator requests are throttled per minute on the Free plan and unthrottled on paid plans. Exceeding the limit returns 429 Too Many Requests; rate-limit usage is reported in the X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset response headers. See per-plan limits and best practices →

Error Codes

The Slot Machine Simulator API uses standard HTTP status codes — 200 on success, 400 for invalid parameters, 401 for missing or invalid keys, 403 for insufficient credits, 429 for rate-limit exhaustion, and 500/503 for server-side issues. Each error response includes an X-Request-ID header you can quote when contacting support. See full error handling guide →

SDKs for Slot Machine Simulator

Official Slot Machine Simulator packages on npm, PyPI, NuGet, and JitPack — plus a Postman collection and an OpenAPI spec. See the SDK guide →

No-Code Integrations

Slot Machine Simulator works with Zapier, Make, Pipedream, n8n, and Power Automate using the same API key. See setup guides →

Frequently Asked Questions

How do I get an API key for Slot Machine Simulator?
Sign up for a free account at dashboard.apiverve.com. Your API key will be automatically generated and available in your dashboard. The same key works for Slot Machine Simulator and all other APIVerve APIs. The free plan includes 1,000 credits plus a 500 credit bonus.
How many credits does Slot Machine Simulator cost?

Each successful Slot Machine Simulator API call consumes credits based on plan tier. Check the pricing section above for the exact credit cost. Failed requests and errors don't consume credits, so you only pay for successful slot machine simulator lookups.

Can I use Slot Machine Simulator in production?

The free plan is for testing and development only. For production use of Slot Machine Simulator, upgrade to a paid plan (Starter, Pro, or Mega) which includes commercial use rights, no attribution requirements, and guaranteed uptime SLAs. All paid plans are production-ready.

Can I use Slot Machine Simulator from a browser?
Yes! The Slot Machine Simulator API supports CORS with wildcard configuration, so you can call it directly from browser-based JavaScript without needing a proxy server. See the CORS section above for details.
What happens if I exceed my Slot Machine Simulator credit limit?

When you reach your monthly credit limit, Slot Machine Simulator API requests will return an error until you upgrade your plan or wait for the next billing cycle. You'll receive notifications at 80% and 95% usage to give you time to upgrade if needed.

What's Next?

Continue your journey with these recommended resources

Was this page helpful?