Complete activation operation
GEThttps://onlinesim.io/api/setOperationOk.php
Closes the operation. POST with the same parameters works too.
- An operation without SMS can be closed only after the protective interval from its start: 120 seconds, 300 seconds for WhatsApp. The interval does not apply to accounts that have spent 100 000 or more.
ban=1closes an operation without SMS as failed and blocks this number from being issued again (for a number in a wrong format). If the operation already has an SMS, the answer is"0"and nothing changes.- An operation that has already failed (
ERROR_NO_ITEMSin getState) is not changed; the answer is still a success. - The same
tzidcan be sent again only after 5 seconds, even when the first request ended with an error.


Security
Parameters
query3
| Name | Type | Description |
|---|---|---|
tzid* | integer | Operation ID from getNum |
ban | integer |
Enum: 01Default:0 |
lang | string | Language of the texts in the answer (country and service names, status texts): Enum: frderuenzh |
Responses
200Operation closed or an error
application/jsonschemaoneOf
[0]object
[1]object
[2]object
[3]object
Examples
Operation closed
{
"response": 1,
"tzid": 10000
}Too early to close
{
"response": "NO_COMPLETE_TZID"
}ban=1 for an operation with an SMS
{
"response": "0"
}429HTTP 429: more than 400 requests per minute from one profile (from one IP for requests without a key), or more than 200 requests per minute from one profile to getNum, getPrice, getState and setOperationOk together
application/jsonschemaobject
Examples
Request rate limit exceeded
{
"response": "TRY_AGAIN_LATER"
}456HTTP 456: the API key is invalid or the OAuth token has expired. Public methods answer the same way when an invalid key is sent
application/jsonschemaobject
Examples
Invalid API key or expired token
{
"response": "ERROR_WRONG_KEY"
}