-
Notifications
You must be signed in to change notification settings - Fork 3
GetNumbers
Pavel Kuzmin edited this page Aug 10, 2020
·
4 revisions
const driver = new OnlineSimDriver('APIKEY').numbers().{method}();
const driver = new OnlineSimDriver('APIKEY');
const getter = driver.numbers()
getter.tariffs().then((result) => {
console.log(result);
})
getter.get('3223').then((result) => {
console.log(result);
})
getter.state().then((result) => {
console.log(result);
})
// or
getter.stateOne(res.tzid).then((result) => {
console.log(result);
})
// next message
getter.next(res.tzid).then((result) => {
console.log(result);
})
...
getter.state().then((result) => {
console.log(result);
})
...
getter.close(res.tzid).then((result) => {
console.log(result);
})
Get new number for service
Params | Default | Description |
---|---|---|
$service | no | https://onlinesim.ru/docs/api/ru#getnum |
$country | 7 | country |
$reject | no | exclusion list |
Get service price
Params | Default | Description |
---|---|---|
$country | 7 | country |
$service | no | https://onlinesim.ru/docs/api/ru#getnum |
Get list number for service
Params | Default | Description |
---|---|---|
$message_to_code | 1 | 1 - show code, 0 - show full message |
$orderby | ASC | ASC or DESC |
$msg_list | true | true - show all message, false show one message< need next method |
$clean | true | if use msg_list===0 - false - display messages in a circle |
Get selected number for service
Params | Default | Description |
---|---|---|
$message_to_code | 1 | 1 - show code, 0 - show full message |
$orderby | ASC | ASC or DESC |
$msg_list | true | true - show all message, false show one message< need next method |
$clean | true | if use msg_list===0 - false - display messages in a circle |
select next message
Params | Default | Description |
---|---|---|
$tzid | no | operation id |
Close selected number for service
Params | Default | Description |
---|---|---|
$tzid | no | operation id |
List tariffs for number for service
© 2013 - 2020. OnlineSim LLC