Slot Machine SimulatorSlot Machine Simulator API

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

Slot Machine Simulator is a tool for simulating slot machine spins with realistic reel symbols and payout calculations. It supports customizable number of reels, bet amounts, and multiple spins with detailed win/loss statistics.

The Slot Machine Simulator API provides reliable and fast access to slot machine simulator data through a simple REST interface. Built for developers who need consistent, high-quality results with minimal setup time.

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

Code Examples

Here are examples of 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)
Node.js (Native HTTPS)
const https = require('https');
const url = require('url');

const options = {
  method: 'GET',
  headers: {
    'X-API-Key': 'your_api_key_here',
    'Content-Type': 'application/json'
  }
};

const req = https.request('https://api.apiverve.com/v1/slotmachine?spins=5&reels=3&bet=1', options, (res) => {
  let data = '';
  res.on('data', (chunk) => data += chunk);
  res.on('end', () => console.log(JSON.parse(data)));
});

req.end();
PHP (cURL)
<?php

$ch = curl_init();

curl_setopt($ch, CURLOPT_URL, 'https://api.apiverve.com/v1/slotmachine?spins=5&reels=3&bet=1');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_HTTPHEADER, [
    'X-API-Key: your_api_key_here',
    'Content-Type: application/json'
]);

$response = curl_exec($ch);
curl_close($ch);

$data = json_decode($response, true);
print_r($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))
}
Ruby (Net::HTTP)
require 'net/http'
require 'json'

uri = URI('https://api.apiverve.com/v1/slotmachine?spins=5&reels=3&bet=1')
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true

request = Net::HTTP::Get.new(uri)
request['X-API-Key'] = 'your_api_key_here'
request['Content-Type'] = 'application/json'

response = http.request(request)
puts JSON.pretty_generate(JSON.parse(response.body))
C# (HttpClient)
using System;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;

class Program
{
    static async Task Main(string[] args)
    {
        using var client = new HttpClient();
        client.DefaultRequestHeaders.Add("X-API-Key", "your_api_key_here");

        var response = await client.GetAsync("https://api.apiverve.com/v1/slotmachine?spins=5&reels=3&bet=1");
        response.EnsureSuccessStatusCode();

        var responseBody = await response.Content.ReadAsStringAsync();
        Console.WriteLine(responseBody);
    }
}

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:

Example Responses

JSON 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
      }
    ]
  }
}
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_spinsnumber5Total number of spins simulated in session
num_reelsnumber3Number of reels used per spin
bet_per_spinnumber1Bet amount placed per individual spin
[ ] Array items:array[5]Array of objectsArray containing detailed information for each spin
spin_numbernumber1Sequential number identifying this spin
[ ] Array items:array[3]Array of objectsArray of reel results for this spin
symbolstring"🍋"Emoji symbol displayed on the reel
namestring"Lemon"Human-readable name of reel symbol
betnumber1Bet amount wagered for this spin
payoutPremiumnumber0Monetary payout amount won from spin
win_typePremiumstring"none"Classification of win result for spin
is_winPremiumbooleanfalseWhether spin resulted in winning combination
total_betnumber5Total amount wagered across all spins
total_winningsPremiumnumber0.5Total monetary winnings from all spins
net_profitPremiumnumber-4.5Calculated profit or loss after all spins
winsPremiumnumber1Count of successful winning spins
lossesPremiumnumber4Count of losing spins in session
win_percentagePremiumnumber20Percentage of spins that resulted in wins
[ ] Array items:array[8]Array of objectsArray of all possible symbols used
symbolstring"🍒"Emoji symbol available in slot machine

Headers

Required and optional headers for Slot Machine Simulator API requests:

Header NameRequiredExample ValueDescription
X-API-Keyrequiredyour_api_key_hereYour APIVerve API key. Found in your dashboard under API Keys.
Acceptoptionalapplication/jsonSpecify response format: application/json (default), application/xml, or application/yaml
User-AgentoptionalMyApp/1.0Identifies your application for analytics and debugging purposes
X-Request-IDoptionalreq_123456789Custom request identifier for tracking and debugging requests
Cache-Controloptionalno-cacheControl caching behavior for the request and response

Learn more about 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 supports Cross-Origin Resource Sharing (CORS) with wildcard configuration, allowing you to call Slot Machine Simulator directly from browser-based applications without proxy servers.

CORS HeaderValueDescription
Access-Control-Allow-Origin*Accepts requests from any origin
Access-Control-Allow-Methods*Accepts any HTTP method
Access-Control-Allow-Headers*Accepts any request headers

Browser Usage: You can call Slot Machine Simulator directly from JavaScript running in the browser without encountering CORS errors. No proxy server or additional configuration needed.

Learn more about CORS support →

Rate Limiting

Slot Machine Simulator API requests are subject to rate limiting based on your subscription plan. These limits ensure fair usage and maintain service quality for all Slot Machine Simulator users.

PlanRate LimitDescription
Free5 requests/minHard rate limit enforced - exceeding will return 429 errors
StarterNo LimitProduction ready - standard traffic priority
ProNo LimitProduction ready - preferred traffic priority
MegaNo LimitProduction ready - highest traffic priority

Learn more about rate limiting →

Rate Limit Headers

When rate limits apply, each Slot Machine Simulator response includes headers to help you track your usage:

HeaderDescription
X-RateLimit-LimitMaximum number of requests allowed per time window
X-RateLimit-RemainingNumber of requests remaining in the current window
X-RateLimit-ResetUnix timestamp when the rate limit window resets

Handling Rate Limits

Free Plan: When you exceed your rate limit, Slot Machine Simulator returns a 429 Too Many Requests status code. Your application should implement appropriate backoff logic to handle this gracefully.

Paid Plans: No rate limiting or throttling applied. All paid plans (Starter, Pro, Mega) are production-ready.

Best Practices for Slot Machine Simulator:

  • Monitor the rate limit headers to track your Slot Machine Simulator usage (Free plan only)
  • Cache slot machine simulator responses where appropriate to reduce API calls
  • Upgrade to Pro or Mega for guaranteed no-throttle Slot Machine Simulator performance

Note: Slot Machine Simulator rate limits are separate from credit consumption. You may have credits remaining but still hit rate limits when using Slot Machine Simulator on Free tier.

Error Codes

The Slot Machine Simulator API uses standard HTTP status codes to indicate success or failure:

CodeMessageDescriptionSolution
200OKRequest successful, data returnedNo action needed - request was successful
400Bad RequestInvalid request parameters or malformed requestCheck required parameters and ensure values match expected formats
401UnauthorizedMissing or invalid API keyInclude x-api-key header with valid API key from dashboard
403ForbiddenAPI key lacks permission or insufficient creditsCheck credit balance in dashboard or upgrade plan
429Too Many RequestsRate limit exceeded (Free: 5 req/min)Implement request throttling or upgrade to paid plan
500Internal Server ErrorServer error occurredRetry request after a few seconds, contact support if persists
503Service UnavailableAPI temporarily unavailableWait and retry, check status page for maintenance updates

Learn more about error handling →

Need help? Contact support with your X-Request-ID for assistance.

Integrate Slot Machine Simulator with SDKs

Get started quickly with official Slot Machine Simulator SDKs for your preferred language. Each library handles authentication, request formatting, and error handling automatically.

Available for Node.js, Python, C#/.NET, and Android/Java. All SDKs are open source and regularly updated.

Integrate Slot Machine Simulator with No-Code API Tools

Connect the Slot Machine Simulator API to your favorite automation platform without writing code. Build workflows that leverage slot machine simulator data across thousands of apps.

All platforms use your same API key to access Slot Machine Simulator. Visit our integrations hub for step-by-step 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?