Provider
Overview
The Provider resource in VoIPBIN represents a telecommunication service provider that offers communication services using the Session Initiation Protocol (SIP) technology. A provider is a crucial component that allows VoIPBIN to connect and communicate with external networks, enabling users to make calls, send messages, and engage in various forms of communication.
Each Provider entry in VoIPBIN contains specific information related to the telecommunication service it offers. This includes the provider’s unique ID, type (e.g., SIP), hostname (e.g., sip.telnyx.com), and other technical details such as tech_prefix, tech_postfix, and tech_headers. These technical parameters define how VoIPBIN interacts with the provider’s infrastructure to establish and manage communication channels.
Furthermore, the Provider resource includes metadata such as the provider’s name, detailed description, and timestamps for creation, update, and deletion. These timestamps help track the history of the provider’s details, ensuring accurate and up-to-date information for administration and auditing purposes.
VoIPBIN’s Provider resource plays a fundamental role in enabling communication services for users. By leveraging different providers, VoIPBIN can connect with multiple external networks, expand its reach, and offer versatile communication capabilities to its users. Each provider may have unique features, pricing structures, and geographic coverage, allowing users to select the most suitable provider for their communication needs.
In summary, the Provider resource is a vital component of VoIPBIN’s communication infrastructure, facilitating seamless connectivity to external networks and empowering users to engage in effective and reliable communication with individuals and businesses across various platforms and locations.
Provider
Provider
{
"id": "<string>",
"name": "<string>",
"detail": "<string>",
"type": "<string>",
"hostname": "<string>",
"tech_prefix": "<string">,
"tech_postfix": "<string>",
"tech_headers": {
"<string>": "<string">,
},
"tm_create": "<string>",
"tm_update": "<string>",
"tm_delete": "<string>"
}
id: Provider’s id.
name: Provider’s name.
detail: Provider’s detail.
type: Provider’s type. See detail here.
tech_prefix: Tech prefix. Will be attacehd to the beginning of the destination. Valid only the type sip.
tech_postfix: Tech postfix. Will be attacehd to the end of the destination. Valid only the type sip.
tech_headers: Key/value fair of SIP headers. Valid only the type sip.
example
{
"id": "4dbeabd6-f397-4375-95d2-a38411e07ed1",
"type": "sip",
"hostname": "sip.telnyx.com",
"tech_prefix": "",
"tech_postfix": "",
"tech_headers": {},
"name": "telnyx basic",
"detail": "telnyx basic",
"tm_create": "2022-10-22 16:16:16.874761",
"tm_update": "2022-10-24 04:53:14.171374",
"tm_delete": "9999-01-01 00:00:00.000000"
}
Type
Defines types of provider.
Type |
Description |
---|---|
sip |
SIP service provider. |
Tutorial
Get list of providers
Example
$ curl -k --location --request GET 'https://api.voipbin.net/v1.0/providers?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjdXN0b21lciI6IntcImlkXCI6XCI1ZTRhMDY4MC04MDRlLTExZWMtODQ3Ny0yZmVhNTk2OGQ4NWJcIixcInVzZXJuYW1lXCI6XCJhZG1pblwiLFwibmFtZVwiOlwiYWRtaW5cIixcImRldGFpbFwiOlwiYWRtaW4gYWNjb3VudFwiLFwid2ViaG9va19tZXRob2RcIjpcIlBPU1RcIixcIndlYmhvb2tfdXJpXCI6XCJodHRwczovL2VuN2V2YWp3aG1xYnQueC5waXBlZHJlYW0ubmV0XCIsXCJsaW5lX3NlY3JldFwiOlwiYmE1ZjA1NzVkODI2ZDViNGEwNTJhNDMxNDVlZjEzOTFcIixcImxpbmVfdG9rZW5cIjpcInRzZklpREIvMmNHSTVzSFJNSW9wN1MzU1M0S3NiRWxKL3VrUUtzNkxwSFkxWG9HMnBUTUhxZGl5TE51OGFNZGEycGkzdlRYc2NDS3A4WEdFdmZsNmRtSVQxbmZUVGRNa21ZODRpUkxJT0lBbDg1aUcvWFp1ZUkxV0JSdmNoZlY4VGxad0RtRUNiU1N6TCtXdXYrak8rZ2RCMDR0ODkvMU8vdzFjRG55aWxGVT1cIixcInBlcm1pc3Npb25faWRzXCI6W1wiMDM3OTZlMTQtN2NiNC0xMWVjLTlkYmEtZTcyMDIzZWZkMWM2XCJdLFwidG1fY3JlYXRlXCI6XCIyMDIyLTAyLTAxIDAwOjAwOjAwLjAwMDAwMFwiLFwidG1fdXBkYXRlXCI6XCIyMDIyLTA2LTE2IDA4OjM3OjE2Ljk1MjczOFwiLFwidG1fZGVsZXRlXCI6XCI5OTk5LTAxLTAxIDAwOjAwOjAwLjAwMDAwMFwifSIsImV4cCI6MTY2Nzc4ODg2OX0.ZI8v3vgBaUQq7Qemlbb0m3hNEtacYzRHtEX98GCRTL0'
{
"result": [
{
"id": "4dbeabd6-f397-4375-95d2-a38411e07ed1",
"type": "sip",
"hostname": "sip.telnyx.com",
"tech_prefix": "",
"tech_postfix": "",
"tech_headers": {},
"name": "telnyx basic",
"detail": "telnyx basic",
"tm_create": "2022-10-22 16:16:16.874761",
"tm_update": "2022-10-24 04:53:14.171374",
"tm_delete": "9999-01-01 00:00:00.000000"
}
...
],
"next_page_token": "2022-10-22 16:16:16.874761"
}
Get detail of provider
Example
$ curl -k --location --request GET 'https://api.voipbin.net/v1.0/outplans/d5fb7357-7ddb-4f2d-87b5-8ccbfd6c039e?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE2MTUwNTQxMjYsInVzZXIiOnsiaWQiOjEsInBlcm1pc3Npb24iOjEsInVzZXJuYW1lIjoiYWRtaW4ifX0.uV26jlo9kdV-qxxj32cjNa99JRcD96HkFF0h_cuEXLA'
{
"id": "d5fb7357-7ddb-4f2d-87b5-8ccbfd6c039e",
"name": "test outplan",
"detail": "outplan for test use.",
"source": {
"type": "tel",
"target": "+821021656521",
"target_name": "",
"name": "",
"detail": ""
},
"dial_timeout": 30000,
"try_interval": 60000,
"max_try_count_0": 5,
"max_try_count_1": 5,
"max_try_count_2": 5,
"max_try_count_3": 5,
"max_try_count_4": 5,
"tm_create": "2022-04-28 01:50:23.414000",
"tm_update": "2022-04-30 12:01:13.780469",
"tm_delete": "9999-01-01 00:00:00.000000"
}
Create a new provider
Example
$ curl --location --request POST 'https://api.voipbin.net/v1.0/providers?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjdXN0b21lciI6IntcImlkXCI6XCI1ZTRhMDY4MC04MDRlLTExZWMtODQ3Ny0yZmVhNTk2OGQ4NWJcIixcInVzZXJuYW1lXCI6XCJhZG1pblwiLFwibmFtZVwiOlwiYWRtaW5cIixcImRldGFpbFwiOlwiYWRtaW4gYWNjb3VudFwiLFwid2ViaG9va19tZXRob2RcIjpcIlBPU1RcIixcIndlYmhvb2tfdXJpXCI6XCJodHRwczovL2VuN2V2YWp3aG1xYnQueC5waXBlZHJlYW0ubmV0XCIsXCJsaW5lX3NlY3JldFwiOlwiYmE1ZjA1NzVkODI2ZDViNGEwNTJhNDMxNDVlZjEzOTFcIixcImxpbmVfdG9rZW5cIjpcInRzZklpREIvMmNHSTVzSFJNSW9wN1MzU1M0S3NiRWxKL3VrUUtzNkxwSFkxWG9HMnBUTUhxZGl5TE51OGFNZGEycGkzdlRYc2NDS3A4WEdFdmZsNmRtSVQxbmZUVGRNa21ZODRpUkxJT0lBbDg1aUcvWFp1ZUkxV0JSdmNoZlY4VGxad0RtRUNiU1N6TCtXdXYrak8rZ2RCMDR0ODkvMU8vdzFjRG55aWxGVT1cIixcInBlcm1pc3Npb25faWRzXCI6W1wiMDM3OTZlMTQtN2NiNC0xMWVjLTlkYmEtZTcyMDIzZWZkMWM2XCJdLFwidG1fY3JlYXRlXCI6XCIyMDIyLTAyLTAxIDAwOjAwOjAwLjAwMDAwMFwiLFwidG1fdXBkYXRlXCI6XCIyMDIyLTA2LTE2IDA4OjM3OjE2Ljk1MjczOFwiLFwidG1fZGVsZXRlXCI6XCI5OTk5LTAxLTAxIDAwOjAwOjAwLjAwMDAwMFwifSIsImV4cCI6MTY2Nzc4ODg2OX0.ZI8v3vgBaUQq7Qemlbb0m3hNEtacYzRHtEX98GCRTL0' \
--header 'Content-Type: application/json' \
--data-raw '{
"type": "sip",
"hostname": "test.com",
"tech_prefix": "",
"tech_postfix": "",
"tech_headers": {},
"name": "test domain",
"detail": "test domain creation"
}'
Update provider
Example
$ curl --location --request PUT 'https://api.voipbin.net/v1.0/providers/4dbeabd6-f397-4375-95d2-a38411e07ed1?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjdXN0b21lciI6IntcImlkXCI6XCI1ZTRhMDY4MC04MDRlLTExZWMtODQ3Ny0yZmVh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tZVwiOlwiYWRtaW5cIixcImRldGFpbFwiOlwiYWRtaW4gYWNjb3VudFwiLFwid2ViaG9va19tZXRob2RcIjpcIlBPU1RcIixcIndlYmhvb2tfdXJpXCI6XCJodHRwczovL2VuN2V2YWp3aG1xYnQueC5waXBlZHJlYW0ubmV0XCIsXCJsaW5lX3NlY3JldFwiOlwiYmE1ZjA1NzVkODI2ZDViNGEwNTJhNDMxNDVlZjEzOTFcIixcImxpbmVfdG9rZW5cIjpcInRzZklpREIvMmNHSTVzSFJNSW9wN1MzU1M0S3NiRWxKL3VrUUtzNkxwSFkxWG9HMnBUTUhxZGl5TE51OGFNZGEycGkzdlRYc2NDS3A4WEdFdmZsNmRtSVQxbmZUVGRNa21ZODRpUkxJT0lBbDg1aUcvWFp1ZUkxV0JSdmNoZlY4VGxad0RtRUNiU1N6TCtXdXYrak8rZ2RCMDR0ODkvMU8vdzFjRG55aWxGVT1cIixcInBlcm1pc3Npb25faWRzXCI6W1wiMDM3OTZlMTQtN2NiNC0xMWVjLTlkYmEtZTcyMDIzZWZkMWM2XCJdLFwidG1fY3JlYXRlXCI6XCIyMDIyLTAyLTAxIDAwOjAwOjAwLjAwMDAwMFwiLFwidG1fdXBkYXRlXCI6XCIyMDIyLTA2LTE2IDA4OjM3OjE2Ljk1MjczOFwiLFwidG1fZGVsZXRlXCI6XCI5OTk5LTAxLTAxIDAwOjAwOjAwLjAwMDAwMFwifSIsImV4cCI6MTY2Nzc4ODg2OX0.ZI8v3vgBaUQq7Qemlbb0m3hNEtacYzRHtEX98GCRTL0' \
--data-raw '{
"type": "sip",
"hostname": "sip.telnyx.com",
"tech_prefix": "",
"tech_postfix": "",
"tech_headers": {},
"name": "telnyx basic",
"detail": "telnyx basic"
}'
Delete provider
Example
$ curl --location --request DELETE 'https://api.voipbin.net/v1.0/providers/7efc9379-2d3e-4e54-9d36-23cff676a83e?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjdXN0b21lciI6IntcImlkXCI6XCI1ZTRhMDY4MC04MDRlLTExZWMtODQ3Ny0yZmVhNTk2OGQ4NWJcIixcInVzZXJuYW1lXCI6XCJhZG1pblwiLFwibmFtZVwiOlwiYWRtaW5cIixcImRldGFpbFwiOlwiYWRtaW4gYWNjb3VudFwiLFwid2ViaG9va19tZXRob2RcIjpcIlBPU1RcIixcIndlYmhvb2tfdXJpXCI6XCJodHRwczovL2VuN2V2YWp3aG1xYnQueC5waXBlZHJlYW0ubmV0XCIsXCJsaW5lX3NlY3JldFwiOlwiYmE1ZjA1NzVkODI2ZDViNGEwNTJhNDMxNDVlZjEzOTFcIixcImxpbmVfdG9rZW5cIjpcInRzZklpREIvMmNHSTVzSFJNSW9wN1MzU1M0S3NiRWxKL3VrUUtzNkxwSFkxWG9HMnBUTUhxZGl5TE51OGFNZGEycGkzdlRYc2NDS3A4WEdFdmZsNmRtSVQxbmZUVGRNa21ZODRpUkxJT0lBbDg1aUcvWFp1ZUkxV0JSdmNoZlY4VGxad0RtRUNiU1N6TCtXdXYrak8rZ2RCMDR0ODkvMU8vdzFjRG55aWxGVT1cIixcInBlcm1pc3Npb25faWRzXCI6W1wiMDM3OTZlMTQtN2NiNC0xMWVjLTlkYmEtZTcyMDIzZWZkMWM2XCJdLFwidG1fY3JlYXRlXCI6XCIyMDIyLTAyLTAxIDAwOjAwOjAwLjAwMDAwMFwiLFwidG1fdXBkYXRlXCI6XCIyMDIyLTA2LTE2IDA4OjM3OjE2Ljk1MjczOFwiLFwidG1fZGVsZXRlXCI6XCI5OTk5LTAxLTAxIDAwOjAwOjAwLjAwMDAwMFwifSIsImV4cCI6MTY2Nzc4ODg2OX0.ZI8v3vgBaUQq7Qemlbb0m3hNEtacYzRHtEX98GCRTL0'