User

Balance

Request example

curl "https://5sim.net/v1/user/profile" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "id":1, "email":"mail@gmail.com", "vendor":"demo", "default_forwarding_number":"447350690992", "balance":100, "rating":96, "default_country": { "name":"england","iso":"gb","prefix":"+44" }, "default_operator": { "name":"" }, "frozen_balance":0 }

GET - https://5sim.net/v1/user/profile

Provides profile data: email, balance and rating.

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Response

Status code: 200 OK

NameTypeDescription
idnumberUser ID
emailstringUser email
balancenumberBalance
ratingnumberRating
default_countryarrayDefault country
default_country.namestringCountry name
default_country.isostringISO country code
default_country.prefixstringMobile prefix
default_operatorarrayDefault operator
default_operator.namestringOperator name
frozen_balancenumberFrozen balance
default_forwarding_numberstringDefault forwarding number
vendorstringVendor name

Status code : 401 Unauthorized

Order history

Request example

curl "https://5sim.net/v1/user/orders?category=hosting&limit=15&offset=0&order=id&reverse=true" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "Data": [ { "id":53533933, "phone":"+447350690992", "operator":"vodafone", "product":"facebook", "price":2, "status":"BANNED", "expires":"2020-06-28T16:32:43.307041Z", "sms":[], "created_at":"2020-06-28T16:17:43.307041Z", "country":"england" } ], "ProductNames":[], "Statuses":[], "Total":3 }

GET - https://5sim.net/v1/user/orders?category=$category

Provides orders history by choosen category.

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
categoryquery stringYesCategory can be 'hosting' or 'activation'
limitquery stringNoPagination limit
offsetquery stringNoPagination offset
orderquery stringNoPagination order, should be field name
reversequery stringNoIs reversed history, true / false

Response

Status code : 200 OK

NameTypeDescription
DataarrayOrders list
ProductNamesarrayProducts list
StatusesarrayStatuses list
TotalnumberOrders count

Payments history

Request example

curl "https://5sim.net/v1/user/payments?limit=15&offset=0&order=id&reverse=true" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "Data": [ { "ID":30011934, "TypeName":"charge", "ProviderName":"admin", "Amount":100, "Balance":100, "CreatedAt":"2020-06-24T15:37:08.149895Z" } ], "PaymentTypes": [{"Name":"charge"}], "PaymentProviders":[{"Name":"admin"}], "Total":1 }

GET - https://5sim.net/v1/user/payments

Provides payments history.

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
limitquery stringNoPagination limit
offsetquery stringNoPagination offset
orderquery stringNoPagination order, should be field name
reversequery stringNoIs reversed history, true / false

Response

Status code : 200 OK

NameTypeDescription
DataarrayPayments list
PaymentProvidersarrayNames of payments systems
PaymentTypesarrayPayments types
TotalnumberPayments count

Prices limit

Get a list

Request example

curl "https://5sim.net/v1/user/max-prices" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

[ { "id": 14, "product": "facebook", "price": 11, "CreatedAt": "2020-06-24T15:37:08.149895Z" } ]

GET - https://5sim.net/v1/user/max-prices

Get a list of established price limits.

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Response

NameTypeDescription
idnumberID
productstringProduct name
pricenumberPrice
created_atdate stringThe date and time when the object was created

Status code : 200 OK

Status code : 401 Unauthorized

Create or update the price limit per product

Request example

curl -X POST "https://5sim.net/v1/user/max-prices" \ -d '{"product_name": "facebook", "price": 30}'\ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

POST - https://5sim.net/v1/user/max-prices

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
product_namequery stringYesProduct name
pricequery numberYesPrice

Status code : 200 - success

Status code : 400 - record not found

Status code : 400 - any error

Status code : 400 - product_name is empty

Delete the price limit per product

Request example

curl -X DELETE "https://5sim.net/v1/user/max-prices" \ -d '{"product_name": "facebook"}'\ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

DELETE - https://5sim.net/v1/user/max-prices

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
product_namequery stringYesProduct name

Status code : 200 - success

Status code : 400 - record not found

Status code : 400 - any error

Status code : 400 - product_name is empty

Products and prices

Products request

Request example

curl "https://5sim.net/v1/guest/products/$country/$operator" \ -H "Accept: application/json"

Response example

{ "1day":{"Category":"hosting","Qty":14,"Price":80}, "facebook":{"Category":"activation","Qty":133,"Price":21} }

GET - https://5sim.net/v1/guest/products/$country/$operator

To receive the name, the price, quantity of all products, available to buy.

Headers

  • Accept: application/json

Request parameters

NameTypeRequiredDescription
countryquery stringYesThe country, "any" - any country
operatorquery stringYesThe operator, "any" - any operator

Response

Status code : 200 OK

NameTypeDescription
Categorystringactivation/hosting
QtynumberAvailable quantity
PricenumberPrice

Prices request

Request example

curl "https://5sim.net/v1/guest/prices" \ -H "Accept: application/json"

Response example

{ "england":{ "facebook":{ "vodafone":{ "cost":4, "count":1260, "rate": 99.99 }, "virtual60":{ "cost":4, "count":935, "rate": 99.99 }, "virtual52":{ "cost":4, "count":0, "rate": 99.99 } } } }

GET - https://5sim.net/v1/guest/prices

Returns product prices

Headers

  • Accept: application/json

Response

Status code : 200 OK

NameTypeDescription
costfloatVirtual number price, two decimal places
countnumberAvailable quantity
ratefloatDelivery percentage, two decimal places, omitted less than 20% or too few orders

Prices by country

Request example

curl "https://5sim.net/v1/guest/prices?country=$country" \ -H "Accept: application/json"

Response example

{ "england":{ "facebook":{ "vodafone":{ "cost":4, "count":1260, "rate": 99.99 }, "virtual60":{ "cost":4, "count":935, "rate": 99.99 }, "virtual52":{ "cost":4, "count":0, "rate": 99.99 } } } }

GET - https://5sim.net/v1/guest/prices?country=$country

Returns product prices by country

Headers

  • Accept: application/json

Request parameters

NameTypeRequiredDescription
countryquery stringYesCountry name

Response

Status code : 200 OK

Status code : 400 country is incorrect

NameTypeDescription
costfloatVirtual number price, two decimal places
countnumberAvailable quantity
ratefloatDelivery percentage, two decimal places, omitted less than 20% or too few orders

Prices by product

Request example

curl "https://5sim.net/v1/guest/prices?product=$product" \ -H "Accept: application/json"

Response example

{ "facebook":{ "afghanistan":{ "virtual18":{ "cost":4, "count":1260, "rate": 99.99 }, "virtual23":{ "cost":4, "count":935, "rate": 99.99 }, "virtual4":{ "cost":4, "count":0, "rate": 99.99 } } } }

GET - https://5sim.net/v1/guest/prices?product=$product

Returns product prices for a specific product

Headers

  • Accept: application/json

Request parameters

NameTypeRequiredDescription
productquery stringYesProduct name

Response

Status code : 200 OK

Status code : 400 product is incorrect

NameTypeDescription
costfloatVirtual number price, two decimal places
countnumberAvailable quantity
ratefloatDelivery percentage, two decimal places, omitted less than 20% or too few orders

Prices by country and product

Request example

curl "https://5sim.net/v1/guest/prices?country=$country&product=$product" \ -H "Accept: application/json"

Response example

{ "england":{ "facebook":{ "vodafone":{ "cost":8, "count":0, "rate": 99.99 }, "matrix":{ "cost":8, "count":0, "rate": 99.99 }, "virtual60":{ "cost":8, "count":0, "rate": 99.99 }, "virtual52":{ "cost":8, "count":0, "rate": 99.99 }, "ee":{ "cost":8, "count":0, "rate": 99.99 }, "virtual59":{ "cost":8, "count":0, "rate": 99.99 }, "virtual15":{ "cost":8, "count":0, "rate": 99.99 }, "vodafone":{ "cost":8, "count":0, "rate": 99.99 } } } }

GET - https://5sim.net/v1/guest/prices?country=$country&product=$product

Returns product prices by country and specific product

Headers

  • Accept: application/json

Request parameters

NameTypeRequiredDescription
countryquery stringYesCountry name
productquery stringYesProduct name

Response

Status code : 200 OK

Status code : 400 country is incorrect

Status code : 400 product is incorrect

NameTypeDescription
costfloatVirtual number price, two decimal places
countnumberAvailable quantity
ratefloatDelivery percentage, two decimal places, omitted less than 20% or too few orders

Purchase

Buy activation number

Request example

curl "https://5sim.net/v1/user/buy/activation/$country/$operator/$product" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "id":11631253, "phone":"+447350690992", "operator":"vodafone", "product":"facebook", "price":21, "status":"PENDING", "expires":"2018-10-13T08:28:38.809469028Z", "sms":null, "created_at":"2018-10-13T08:13:38.809469028Z", "forwarding":false, "forwarding_number":"", "country":"england" }

GET - https://5sim.net/v1/user/buy/activation/$country/$operator/$product

GET - https://5sim.net/v1/user/buy/activation/$country/$operator/$product?forwarding=$forwarding&number=$number&reuse=$reuse&voice=$voice&ref=$ref

Headers

  • Authorization: Bearer $token
  • Accept: application/json

URL parameters

NameTypeRequiredDescription
countryquery stringYesThe country, "any" - any country
operatorquery stringYesThe operator, "any" - any operator
productquery stringYesProduct name

Query parameters

NameTypeRequiredDescription
forwardingquery stringNoWhether or not to enable forwarding
numberquery stringNoNumber for which the call will be forwarded, 11 digits, without the + sign
reusequery stringNoIf equal to "1" buy with the ability to reuse the number, if available
voicequery stringNoIf equal to "1" buy with the ability to receive a call from the robot, if available
refquery stringNoYour referral key if you have it, if you are developer of the software, you can read terms here
maxPricequery stringNoMax price specified in the Purchase method parameters shall have priority over the settings adjusted in the Max purchase price section and shall work only if the operator value is set as "any"

Response

Status code : 200 OK

NameTypeDescription
idnumberOrder ID
phonestringPhone number
operatorstringOperator
productstringProduct
pricenumberPrice
statusstringOrder's status
expiresdate stringWhen the order expires
smssms arraySMS list
created_atdate stringWhen the order was created
forwardingbooleanWhether or not to enable forwarding
forwarding_numberstringCall forwarding number
countrystringName of country of number

Status code : 200 no free phones

Status code : 400

  • not enough user balance
  • not enough rating
  • select country
  • select operator
  • bad country
  • bad operator
  • no product
  • server offline

Status code : 500 internal error

Request limits

Maximum waiting time is 15 minutes. Timeout no sms 5 minute

Buy hosting number

Request example

curl "https://5sim.net/v1/user/buy/hosting/$country/$operator/$product" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "id": 1, "phone": "+447350690992", "product": "facebook", "price": 1, "status": "PENDING", "expires": "1970-12-01T03:00:00.000000Z", "sms": [ { "id":3027531, "created_at":"1970-12-01T17:23:25.106597Z", "date":"1970-12-01T17:23:15Z", "sender":"Facebook", "text":"Use 415127 as your login code", "code":"415127" } ], "created_at": "1970-12-01T00:00:00.000000Z" }

GET - https://5sim.net/v1/user/buy/hosting/$country/$operator/$product

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
countryquery stringYesThe country, "any" - any country
operatorquery stringYesThe operator, "any" - any operator
productquery stringYesProduct name, {3hours, facebook}

Response

Status code : 200 OK

NameTypeDescription
idnumberOrder ID
phonestringPhone number
productstringProduct
pricenumberPrice
statusstringOrder's status
expiresdate stringWhen the order expires
smssms arraySMS list
created_atdate stringWhen the order was created

Status code : 400

  • no free phones
  • not enough user balance
  • not enough rating
  • select country
  • select operator
  • bad country
  • bad operator
  • no product
  • server offline

Status code : 500 internal error

Re-buy number

Request example

curl "https://5sim.net/v1/user/reuse/$product/$number" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

GET - https://5sim.net/v1/user/reuse/$product/$number

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
productquery stringYesProduct name
numberquery stringYesPhone number, 4-15 digits (without the + sign)

Response

Status code : 200 OK

Status code : 400

  • no free phones
  • select operator
  • not enough user balance
  • bad country
  • bad operator
  • server offline
  • not enough rating
  • no product
  • reuse not possible
  • reuse false
  • reuse expired

Status code : 500 internal error

Order management

Check order (Get SMS)

Request example

curl "https://5sim.net/v1/user/check/$id" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "id": 11631253, "created_at": "2018-10-13T08:13:38.809469028Z", "phone": "+447350690992", "product": "facebook", "price": 21, "status": "RECEIVED", "expires": "2018-10-13T08:28:38.809469028Z", "sms": [ { "created_at":"2018-10-13T08:20:38.809469028Z", "date":"2018-10-13T08:19:38Z", "sender":"Facebook", "text":"Facebook: 09363 - use this code to reclaim your suspended profile.", "code":"09363" } ], "forwarding": false, "forwarding_number": "", "country":"england" }

GET - https://5sim.net/v1/user/check/$id

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
idquery stringYesOrder ID

Response

Status code : 200 OK

NameTypeDescription
idnumberOrder ID
created_atdate stringWhen the order was created
phonestringPhone number
productstringProduct
pricenumberPrice
statusstringOrder's status
expiresdate stringWhen the order expires
smssms arraySMS list
forwardingbooleanWhether or not to enable forwarding
forwarding_numberstringCall forwarding number
countrystringName of country of number

Status code : 404 order not found

Status code : 500 internal error

Finish order

Request example

curl "https://5sim.net/v1/user/finish/$id" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "id": 11631253, "created_at": "2018-10-13T08:13:38.809469028Z", "phone": "+447350690992", "product": "facebook", "price": 21, "status": "FINISHED", "expires": "2018-10-13T08:28:38.809469028Z", "sms": [ { "created_at":"2018-10-13T08:20:38.809469028Z", "date":"2018-10-13T08:19:38Z", "sender":"Facebook", "text":"Facebook: 09363 - use this code to reclaim your suspended profile.", "code":"09363" } ], "forwarding": false, "forwarding_number": "", "country":"england" }

GET - https://5sim.net/v1/user/finish/$id

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
idquery stringYesOrder ID

Response

Status code : 200 OK

NameTypeDescription
idnumberOrder ID
created_atdate stringWhen the order was created
phonestringPhone number
productstringProduct
pricenumberPrice
statusstringOrder's status
expiresdate stringWhen the order expires
smssms arraySMS list
forwardingbooleanWhether or not to enable forwarding
forwarding_numberstringCall forwarding number
countrystringName of country of number

Cancel order

Request example

curl "https://5sim.net/v1/user/cancel/$id" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "id": 11631253, "created_at": "2018-10-13T08:13:38.809469028Z", "phone": "+447350690992", "product": "facebook", "price": 21, "status": "CANCELED", "expires": "2018-10-13T08:28:38.809469028Z", "sms": [ { "created_at":"2018-10-13T08:20:38.809469028Z", "date":"2018-10-13T08:19:38Z", "sender":"Facebook", "text":"Facebook: 09363 - use this code to reclaim your suspended profile.", "code":"09363" } ], "forwarding": false, "forwarding_number": "", "country":"england" }

GET - https://5sim.net/v1/user/cancel/$id

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
idquery stringYesOrder ID

Response

Status code : 200 OK

NameTypeDescription
idnumberOrder ID
created_atdate stringWhen the order was created
phonestringPhone number
productstringProduct
pricenumberPrice
statusstringOrder's status
expiresdate stringWhen the order expires
smssms arraySMS list
forwardingbooleanWhether or not to enable forwarding
forwarding_numberstringCall forwarding number
countrystringName of country of number

Status code : 400 order not found

Status code : 400 order expired

Status code : 400 order has sms

Status code : 400 hosting order

Ban order

Request example

curl "https://5sim.net/v1/user/bn/$id" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "id": 11631253, "created_at": "2018-10-13T08:13:38.809469028Z", "phone": "+447350690992", "product": "facebook", "price": 21, "status": "BANNED", "expires": "2018-10-13T08:28:38.809469028Z", "sms": [ { "created_at":"2018-10-13T08:20:38.809469028Z", "date":"2018-10-13T08:19:38Z", "sender":"Facebook", "text":"Facebook: 09363 - use this code to reclaim your suspended profile.", "code":"09363" } ], "forwarding": false, "forwarding_number": "", "country":"england" }

GET - https://5sim.net/v1/user/ban/$id

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
idquery stringYesOrder ID

Response

Status code : 200 OK

NameTypeDescription
idnumberOrder ID
created_atdate stringWhen the order was created
phonestringPhone number
productstringProduct
pricenumberPrice
statusstringOrder's status
expiresdate stringWhen the order expires
smssms arraySMS list
forwardingbooleanWhether or not to enable forwarding
forwarding_numberstringCall forwarding number
countrystringName of country of number

Status code : 400 order not found

Status code : 400 order expired

Status code : 400 order has sms

Status code : 400 hosting order

SMS inbox list

Request example

curl "https://5sim.net/v1/user/sms/inbox/$id" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "Data": [ { "ID":844928, "created_at":"2017-09-05T15:48:33.763297Z", "date":"2017-09-05T15:48:27Z", "sender":"+447350690992", "text":"12345", "code":"", "is_wave":false, "wave_uuid":"" } ], "Total":1 }

GET - https://5sim.net/v1/user/sms/inbox/$id

Get SMS inbox list by order's id.

Important: This endpoint is available only for rented numbers. It does not work with one-time numbers used for service activations.

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
idquery stringYesOrder ID

Response

Status code : 200 OK

NameTypeDescription
DataarraySMS list
TotalnumberSMS count

Status code : 400 order not found

Status code : 404 record not found

Status code : 500 internal error

Notifications

Get notifications

Request example

curl "https://5sim.net/v1/guest/flash/$lang" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "text":"...notification text..." }

GET - https://5sim.net/v1/guest/flash/$lang

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
langquery stringYesLanguage of notification, en

Response

Status code : 200 OK

NameTypeDescription
textstringNotification text

Vendor

Vendor statistic

Request example

curl "https://5sim.net/v1/user/vendor" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "id":1, "email":"mail@gmail.com", "vendor":"demo", "default_forwarding_number":"447350690992", "balance":100, "rating":96, "default_country": { "name":"england","iso":"gb","prefix":"+44" }, "default_operator": { "name":"" }, "frozen_balance":0 }

GET - https://5sim.net/v1/user/vendor

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Response

Status code : 200 OK

NameTypeDescription
idnumberVendor ID
emailstringVendor email
balancenumberBalance
ratingnumberRating
default_countryarrayDefault country
default_country.namestringCountry name
default_country.isostringISO country code
default_country.prefixstringMobile prefix
default_operatorarrayDefault operator
default_operator.namestringOperator name
frozen_balancenumberFrozen balance
default_forwarding_numberstringDefault forwarding number
vendorstringVendor name

Status code : 401 Unauthorized

Wallets reserve

Request example

curl "https://5sim.net/v1/vendor/wallets" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "fkwallet":43339.55, "payeer":2117.32, "unitpay":97.6 }

GET - https://5sim.net/v1/vendor/wallets

Available reserves currency for partner.

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Response

Status code : 200 OK

NameTypeDescription
fkwalletnumber
payeernumber
unitpaynumber

Status code : 401 Unauthorized

Vendor orders history

Request example

curl "https://5sim.net/v1/vendor/orders?category=activation&limit=15&offset=0&order=id&reverse=true" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "Data": [], "ProductNames":[], "Statuses":[], "Total":3 }

GET - https://5sim.net/v1/vendor/orders?category=$category

Provides vendor's orders history by chosen category.

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
categoryquery stringYesCategory can be 'hosting' or 'activation'
limitquery stringNoPagination limit
offsetquery stringNoPagination offset
orderquery stringNoPagination order, should be field name
reversequery stringNoIs reversed history, true / false

Response

Status code : 200 OK

NameTypeDescription
DataarrayOrders list
ProductNamesarrayProducts list
StatusesarrayStatuses list
TotalnumberOrders count

Vendor payments history

Request example

curl "https://5sim.net/v1/vendor/payments?limit=15&offset=0&order=id&reverse=true" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "Data": [], "PaymentProviders":null, "PaymentStatuses":null, "PaymentTypes":null, "Total":3 }

GET - https://5sim.net/v1/vendor/payments

Provides vendor's payments history.

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
limitquery stringNoPagination limit
offsetquery stringNoPagination offset
orderquery stringNoPagination order, should be field name
reversequery stringNoIs reversed history, true / false

Response

Status code : 200 OK

NameTypeDescription
DataarrayPayments list
PaymentProvidersarrayNames of payments systems
PaymentStatusesarrayPayments statuses
PaymentTypesarrayPayments types
TotalnumberPayments count

Create payouts

Request example

curl -X POST "https://5sim.net/v1/vendor/withdraw" \ -d '{"receiver":"1","method":"qiwi","amount":"1","fee":"unitpay"}' \ -H "Authorization: Bearer $token" \ -H "Content-Type: application/json"

POST - https://5sim.net/v1/vendor/withdraw

Create payouts for a partner.

Headers

  • Authorization: Bearer $token
  • Content-Type: application/json

Request parameters

NameTypeRequiredDescription
receiverstringYesReceiver
methodstringYesOutput method visa
amountstringYesAmount
feestringYesPayment system fkwallet / payeer / unitpay

Response

Status code : 200 OK

Vendor Prices

Get prices list

Request example

curl "https://5sim.net/v1/vendor/prices" \ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

Response example

{ "Prices": [ { "Count":0, "CountryName":"england", "ID":333567, "OperatorName":"virtual16", "Price":22, "ProductName":"facebook" } ], "Products": ["facebook"], "Country": ["england"], "Operators": ["virtual16"], "Total":1 }

GET - https://5sim.net/v1/vendor/prices

GET - https://5sim.net/v1/vendor/prices?_filters={"ID":"$ID","ProductName":"$ProductName","CountryName":"$CountryName","OperatorName":"$OperatorName","Enabled":"$Enabled","Count":"$Count","AutoDisabled":"$AutoDisabled"}&_sortDir=$sortDir&_sortField=$sortField&_page=$page&_perPage=$perPage

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
_filter.IDquery stringNoFilter by record ID
_filter.CountryNamequery stringNoFilter by country
_filter.ProductNamequery stringNoFilter by product
_filter.OperatorNamequery stringNoFilter by mobile operator
_filter.Countquery stringNoFilter by available numbers count
_filter.Ratequery stringNoFilter by rate value
_filter.Pricequery stringNoFilter by current price
_filter.Hoursquery stringNoFilter by time validity
_filter.DeletedAtquery stringNoFilter by deletion date
_filter.NewPricequery stringNoFilter by new/updated price
_filter.NewPriceUpdatedAtquery stringNoFilter by last update date of new price
_sortDirquery stringNoSorting direction, can be ASC or DESC
_sortFieldquery stringNoField name to sort by (e.g., Price, Rate, Count)
_pagequery stringNoPage number for pagination
_perPagequery stringNoNumber of items per page

Response

Status code : 200 OK

NameTypeDescription
PricesarrayPrices list
ProductsarrayProducts list
CountriesarrayCountries list
OperatorsarrayOperators list
TotalnumberTotal prices count

Status code : 401 Unauthorized

Create price

Request example

curl -X PUT "https://5sim.net/v1/vendor/prices" \ -d '{"Price": 30, "ProductName": "facebook", "CountryName": "england", "OperatorName": "virtual52"}'\ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

PUT - https://5sim.net/v1/vendor/prices

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequired
PricenumberYes
ProductNamestringYes
CountryNamestringYes
OperatorNamestringYes

Status code : 200 - success

Status code : 400 - ProductName is empty

Change price

Request example

curl -X POST "https://5sim.net/v1/vendor/prices" \ -d '{"Price": 30, "Product": "facebook", "Country": "england", "Operator": "virtual52"}'\ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

POST - https://5sim.net/v1/vendor/prices

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequired
PricenumberYes
ProductstringYes
CountrystringYes
OperatorstringYes

Status code : 200 - success

Status code : 400 - Product is empty

Enable/Disable price

Request example

curl -X POST "https://5sim.net/v1/vendor/prices/disable" \ -d '{"Disable": true, "List": [333567]}'\ -H "Authorization: Bearer $token" \ -H "Accept: application/json"

POST - https://5sim.net/v1/vendor/prices/disable

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Request parameters

NameTypeRequiredDescription
DisablebooleanYesDisable numbers if value is true
ListarrayNoAn array of price ids. If not specified, it will apply to all prices

Status code : 200 - success

Status code : 400 - Product is empty

Countries list

Get countries list

Response example

{ "afghanistan":{ "iso":{ "af":1 }, "prefix":{ "+93":1 }, "text_en":"Afghanistan", "virtual18":{ "activation":1 }, "virtual21":{ "activation":1 }, "virtual23":{ "activation":1 }, "virtual4":{ "activation":1 } } }

GET - https://5sim.net/v1/guest/countries

Returns a list of countries with available operators for purchase.

Headers

  • Authorization: Bearer $token
  • Accept: application/json

Response

Status code : 200 OK

NameTypeDescription
isoarrayISO country code
text_enstringCountry name in English

Countries list

CountryAPI 5SIM

Order statuses

  • PENDING - Preparation
  • RECEIVED - Waiting of receipt of SMS
  • CANCELED - Is cancelled
  • TIMEOUT - A timeout
  • FINISHED - Is complete
  • BANNED - Number banned, when number already used

Products list

Activation:

ServiceAPI 5SIM

Hosting:

  • 3hours
  • 1day
  • 10days
  • 1month

Operators list

In order to get a list of operators, you need authorization.

Structure of SMS

Response example

{ "sms": [ { "created_at":"1970-12-01T17:23:25.106597Z", "date":"1970-12-01T17:23:15Z", "sender":"Facebook", "text":"Use 415127 as your login code", "code":"415127" } ] }
NameTypeDescription
created_atdate stringWhen SMS was created
datedate stringWhen SMS received
senderstringSender name
textstringText of SMS
codestringReceived activation code

Limits

100 requests per second by IP address, http error code 503

100 requests per second by API_KEY, http error code 429

100 requests per second buy number, http error code 503

If requests reach limit within 10 minutes 5 times then ban 10 minutes

Rating

Description of the rating system.

The user's current rating is displayed in the account settings, the "General" tab.

The initial rating for new users is 96 points.

The maximum possible rating is 96 points.

The rating is formed from the following parameters:

ActionsRating (points)
Account replenishment+8
Completed Purchase Before Code Elapsed Time+0.5
Automatically Completed Purchase After Time Allowed To Get Code+0.4
Timeout-0.15
Canceled purchase-0.1
The number was sent to the ban-0.1

If the rating drops to zero, then you will not be able to place an order on the site within 24 hours. After 24 hours, the rating will return to the initial value - 96 points.