numberinsight

package
Version: v0.13.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 5, 2021 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ContextOAuth2 takes an oauth2.TokenSource as authentication for the request.
	ContextOAuth2 = contextKey("token")

	// ContextBasicAuth takes BasicAuth as authentication for the request.
	ContextBasicAuth = contextKey("basic")

	// ContextAccessToken takes a string oauth2 access token as authentication for the request.
	ContextAccessToken = contextKey("accesstoken")

	// ContextAPIKey takes an APIKey as authentication for the request
	ContextAPIKey    = contextKey("apikey")
	ContextAPISecret = contextKey("apisecret")
)

Functions

func CacheExpires

func CacheExpires(r *http.Response) time.Time

CacheExpires helper function to determine remaining time before repeating a request.

Types

type APIClient

type APIClient struct {
	DefaultApi *DefaultApiService
	// contains filtered or unexported fields
}

APIClient manages communication with the Number Insight API API v1.0.7 In most cases there should be only one, shared, APIClient.

func NewAPIClient

func NewAPIClient(cfg *Configuration) *APIClient

NewAPIClient creates a new API client. Requires a userAgent string describing your application. optionally a custom http.Client to allow for advanced features such as caching.

func (*APIClient) ChangeBasePath

func (c *APIClient) ChangeBasePath(path string)

ChangeBasePath changes base path to allow switching to mocks

func (*APIClient) GetConfig

func (c *APIClient) GetConfig() *Configuration

Allow modification of underlying config for alternate implementations and testing Caution: modifying the configuration while live can cause data races and potentially unwanted behavior

type APIKey

type APIKey struct {
	Key    string
	Prefix string
}

APIKey provides API key based authentication to a request passed via context using ContextAPIKey

type APIResponse

type APIResponse struct {
	*http.Response `json:"-"`
	Message        string `json:"message,omitempty"`
	// Operation is the name of the OpenAPI operation.
	Operation string `json:"operation,omitempty"`
	// RequestURL is the request URL. This value is always available, even if the
	// embedded *http.Response is nil.
	RequestURL string `json:"url,omitempty"`
	// Method is the HTTP method used for the request.  This value is always
	// available, even if the embedded *http.Response is nil.
	Method string `json:"method,omitempty"`
	// Payload holds the contents of the response body (which may be nil or empty).
	// This is provided here as the raw response.Body() reader will have already
	// been drained.
	Payload []byte `json:"-"`
}

APIResponse stores the API response returned by the server.

func NewAPIResponse

func NewAPIResponse(r *http.Response) *APIResponse

NewAPIResponse returns a new APIResonse object.

func NewAPIResponseWithError

func NewAPIResponseWithError(errorMessage string) *APIResponse

NewAPIResponseWithError returns a new APIResponse object with the provided error message.

type BasicAuth

type BasicAuth struct {
	UserName string `json:"userName,omitempty"`
	Password string `json:"password,omitempty"`
}

BasicAuth provides basic http authentication to a request passed via context using ContextBasicAuth

type Configuration

type Configuration struct {
	BasePath      string            `json:"basePath,omitempty"`
	Host          string            `json:"host,omitempty"`
	Scheme        string            `json:"scheme,omitempty"`
	DefaultHeader map[string]string `json:"defaultHeader,omitempty"`
	UserAgent     string            `json:"userAgent,omitempty"`
	Debug         bool              `json:"debug,omitempty"`
	Servers       []ServerConfiguration
	HTTPClient    *http.Client
}

Configuration stores the configuration of the API client

func NewConfiguration

func NewConfiguration() *Configuration

NewConfiguration returns a new Configuration object

func (*Configuration) AddDefaultHeader

func (c *Configuration) AddDefaultHeader(key string, value string)

AddDefaultHeader adds a new HTTP header to the default header in the request

func (*Configuration) ServerUrl

func (c *Configuration) ServerUrl(index int, variables map[string]string) (string, error)

ServerUrl returns URL based on server settings

type DefaultApiService

type DefaultApiService service

DefaultApiService DefaultApi service

func (*DefaultApiService) GetNumberInsightAdvanced

func (a *DefaultApiService) GetNumberInsightAdvanced(ctx _context.Context, format string, number string, localVarOptionals *GetNumberInsightAdvancedOpts) (NiResponseJsonAdvanced, *_nethttp.Response, error)

GetNumberInsightAdvanced Advanced Number Insight (sync) Provides [advanced number insight](/number-insight/overview#basic-standard-and-advanced-apis) information about a number synchronously, in the same way that the basic and standard endpoints do. Nexmo recommends accessing the Advanced API **asynchronously** using the `/advanced/async` endpoint, to avoid timeouts. Note that this endpoint also supports `POST` requests.

* @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
* @param format The format of the response
* @param number A single phone number that you need insight about in national or international format.
* @param optional nil or *GetNumberInsightAdvancedOpts - Optional Parameters:
* @param "Country" (optional.String) -  If a number does not have a country code or is uncertain, set the two-character country code. This code must be in ISO 3166-1 alpha-2 format and in upper case. For example, GB or US. If you set country and number is already in [E.164](https://en.wikipedia.org/wiki/E.164) format, country must match the country code in number.
* @param "Cnam" (optional.Bool) -  Indicates if the name of the person who owns the phone number should be looked up and returned in the response. Set to true to receive phone number owner name in the response. This features is available for US numbers only and incurs an additional charge.
* @param "Ip" (optional.String) -  This parameter is deprecated as we are no longer able to retrieve reliable IP data globally from carriers.

@return NiResponseJsonAdvanced

func (*DefaultApiService) GetNumberInsightAsync

func (a *DefaultApiService) GetNumberInsightAsync(ctx _context.Context, format string, callback string, number string, localVarOptionals *GetNumberInsightAsyncOpts) (NiResponseAsync, *_nethttp.Response, error)

GetNumberInsightAsync Advanced Number Insight (async) Provides [advanced number insight](/number-insight/overview#basic-standard-and-advanced-apis) number information **asynchronously** using the URL specified in the `callback` parameter. Nexmo recommends asynchronous use of the Number Insight Advanced API, to avoid timeouts. Note that this endpoint also supports `POST` requests.

* @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
* @param format The format of the response
* @param callback The callback URL
* @param number A single phone number that you need insight about in national or international format.
* @param optional nil or *GetNumberInsightAsyncOpts - Optional Parameters:
* @param "Country" (optional.String) -  If a number does not have a country code or is uncertain, set the two-character country code. This code must be in ISO 3166-1 alpha-2 format and in upper case. For example, GB or US. If you set country and number is already in [E.164](https://en.wikipedia.org/wiki/E.164) format, country must match the country code in number.
* @param "Cnam" (optional.Bool) -  Indicates if the name of the person who owns the phone number should be looked up and returned in the response. Set to true to receive phone number owner name in the response. This features is available for US numbers only and incurs an additional charge.
* @param "Ip" (optional.String) -  This parameter is deprecated as we are no longer able to retrieve reliable IP data globally from carriers.

@return NiResponseAsync

func (*DefaultApiService) GetNumberInsightBasic

func (a *DefaultApiService) GetNumberInsightBasic(ctx _context.Context, format string, number string, localVarOptionals *GetNumberInsightBasicOpts) (NiResponseJsonBasic, *_nethttp.Response, error)

GetNumberInsightBasic Basic Number Insight Provides [basic number insight](/number-insight/overview#basic-standard-and-advanced-apis) information about a number. Note that this endpoint also supports `POST` requests.

* @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
* @param format The format of the response
* @param number A single phone number that you need insight about in national or international format.
* @param optional nil or *GetNumberInsightBasicOpts - Optional Parameters:
* @param "Country" (optional.String) -  If a number does not have a country code or is uncertain, set the two-character country code. This code must be in ISO 3166-1 alpha-2 format and in upper case. For example, GB or US. If you set country and number is already in [E.164](https://en.wikipedia.org/wiki/E.164) format, country must match the country code in number.

@return NiResponseJsonBasic

func (*DefaultApiService) GetNumberInsightStandard

func (a *DefaultApiService) GetNumberInsightStandard(ctx _context.Context, format string, number string, localVarOptionals *GetNumberInsightStandardOpts) (NiResponseJsonStandard, *_nethttp.Response, error)

GetNumberInsightStandard Standard Number Insight Provides [standard number insight](/number-insight/overview#basic-standard-and-advanced-apis) information about a number. Note that this endpoint also supports `POST` requests.

* @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
* @param format The format of the response
* @param number A single phone number that you need insight about in national or international format.
* @param optional nil or *GetNumberInsightStandardOpts - Optional Parameters:
* @param "Country" (optional.String) -  If a number does not have a country code or is uncertain, set the two-character country code. This code must be in ISO 3166-1 alpha-2 format and in upper case. For example, GB or US. If you set country and number is already in [E.164](https://en.wikipedia.org/wiki/E.164) format, country must match the country code in number.
* @param "Cnam" (optional.Bool) -  Indicates if the name of the person who owns the phone number should be looked up and returned in the response. Set to true to receive phone number owner name in the response. This features is available for US numbers only and incurs an additional charge.

@return NiResponseJsonStandard

type GenericOpenAPIError

type GenericOpenAPIError struct {
	// contains filtered or unexported fields
}

GenericOpenAPIError Provides access to the body, error and model on returned errors.

func (GenericOpenAPIError) Body

func (e GenericOpenAPIError) Body() []byte

Body returns the raw bytes of the response

func (GenericOpenAPIError) Error

func (e GenericOpenAPIError) Error() string

Error returns non-empty string if there was an error.

func (GenericOpenAPIError) Model

func (e GenericOpenAPIError) Model() interface{}

Model returns the unpacked model of the error

type GetNumberInsightAdvancedOpts

type GetNumberInsightAdvancedOpts struct {
	Country optional.String
	Cnam    optional.Bool
	Ip      optional.String
}

GetNumberInsightAdvancedOpts Optional parameters for the method 'GetNumberInsightAdvanced'

type GetNumberInsightAsyncOpts

type GetNumberInsightAsyncOpts struct {
	Country optional.String
	Cnam    optional.Bool
	Ip      optional.String
}

GetNumberInsightAsyncOpts Optional parameters for the method 'GetNumberInsightAsync'

type GetNumberInsightBasicOpts

type GetNumberInsightBasicOpts struct {
	Country optional.String
}

GetNumberInsightBasicOpts Optional parameters for the method 'GetNumberInsightBasic'

type GetNumberInsightStandardOpts

type GetNumberInsightStandardOpts struct {
	Country optional.String
	Cnam    optional.Bool
}

GetNumberInsightStandardOpts Optional parameters for the method 'GetNumberInsightStandard'

type NiBasicStatus

type NiBasicStatus int32

NiBasicStatus Code | Text -- | -- 0 | Success - request accepted for delivery by Nexmo. 1 | Busy - you have made more requests in the last second than are permitted by your Nexmo account. Please retry. 3 | Invalid - your request is incomplete and missing some mandatory parameters. 4 | Invalid credentials - the _api_key_ or _api_secret_ you supplied is either not valid or has been disabled. 5 | Internal Error - the format of the recipient address is not valid. 9 | Partner quota exceeded - your Nexmo account does not have sufficient credit to process this request.

type NiCallerIdentity

type NiCallerIdentity struct {
	// The value will be `business` if the owner of a phone number is a business. If the owner is an individual the value will be `consumer`. The value will be `unknown` if this information is not available. This parameter is only present if `cnam` had a value of `true` within the request.
	CallerType string `json:"caller_type,omitempty"`
	// Full name of the person or business who owns the phone number. `unknown` if this information is not available. This parameter is only present if `cnam` had a value of `true` within the request.
	CallerName string `json:"caller_name,omitempty"`
	// First name of the person who owns the phone number if the owner is an individual. This parameter is only present if `cnam` had a value of `true` within the request.
	FirstName string `json:"first_name,omitempty"`
	// Last name of the person who owns the phone number if the owner is an individual. This parameter is only present if `cnam` had a value of `true` within the request.
	LastName string `json:"last_name,omitempty"`
}

NiCallerIdentity Information about the network `number` is currently connected to.

type NiCurrentCarrierProperties

type NiCurrentCarrierProperties struct {
	// The [https://en.wikipedia.org/wiki/Mobile_country_code](https://en.wikipedia.org/wiki/Mobile_country_code) for the carrier`number` is associated with. Unreal numbers are marked as`unknown` and the request is rejected altogether if the number is impossible according to the [E.164](https://en.wikipedia.org/wiki/E.164) guidelines.
	NetworkCode string `json:"network_code,omitempty"`
	// The full name of the carrier that `number` is associated with.
	Name string `json:"name,omitempty"`
	// The country that `number` is associated with. This is in ISO 3166-1 alpha-2   format.
	Country string `json:"country,omitempty"`
	// The type of network that `number` is associated with.
	NetworkType string `json:"network_type,omitempty"`
}

NiCurrentCarrierProperties Information about the network `number` is currently connected to.

type NiInitialCarrierProperties

type NiInitialCarrierProperties struct {
	// The [https://en.wikipedia.org/wiki/Mobile_country_code](https://en.wikipedia.org/wiki/Mobile_country_code) for the carrier`number` is associated with. Unreal numbers are marked as`unknown` and the request is rejected altogether if the number is impossible according to the [E.164](https://en.wikipedia.org/wiki/E.164) guidelines.
	NetworkCode string `json:"network_code,omitempty"`
	// The full name of the carrier that `number` is associated with.
	Name string `json:"name,omitempty"`
	// The country that `number` is associated with. This is in ISO 3166-1 alpha-2   format.
	Country string `json:"country,omitempty"`
	// The type of network that `number` is associated with.
	NetworkType string `json:"network_type,omitempty"`
}

NiInitialCarrierProperties Information about the network `number` is currently connected to.

type NiResponseAsync

type NiResponseAsync struct {
	// The unique identifier for your request. This is a alphanumeric string up to 40 characters.
	RequestId string `json:"request_id,omitempty"`
	// The `number` in your request
	Number string `json:"number,omitempty"`
	// Your account balance in EUR after this request.
	RemainingBalance string `json:"remaining_balance,omitempty"`
	// If there is an internal lookup error, the `refund_price` will reflect the lookup price. If `cnam` is requested for a non-US number the `refund_price` will reflect the `cnam` price. If both of these conditions occur, `refund_price` is the sum of the lookup price and `cnam` price.
	RequestPrice  string                   `json:"request_price,omitempty"`
	Status        NiStandardAdvancedStatus `json:"status,omitempty"`
	StatusMessage string                   `json:"error_text,omitempty"`
}

NiResponseAsync struct for NiResponseAsync

type NiResponseJsonAdvanced

type NiResponseJsonAdvanced struct {
	Status NiStandardAdvancedStatus `json:"status"`
	// The status description of your request.
	StatusMessage string `json:"status_message"`
	// The unique identifier for your request. This is a alphanumeric string up to 40 characters.
	RequestId string `json:"request_id"`
	// The `number` in your request in international format.
	InternationalFormatNumber string `json:"international_format_number"`
	// The `number` in your request in the format used by the country the number belongs to.
	NationalFormatNumber string `json:"national_format_number"`
	// Two character country code for `number`. This is in [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
	CountryCode string `json:"country_code"`
	// Three character country code for `number`. This is in [ISO 3166-1 alpha-3](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-3) format.
	CountryCodeIso3 string `json:"country_code_iso3"`
	// The full name of the country that `number` is registered in.
	CountryName string `json:"country_name"`
	// The numeric prefix for the country that `number` is registered in.
	CountryPrefix string `json:"country_prefix"`
	// The amount in EUR charged to your account.
	RequestPrice string `json:"request_price,omitempty"`
	// If there is an internal lookup error, the `refund_price` will reflect the lookup price. If `cnam` is requested for a non-US number the `refund_price` will reflect the `cnam` price. If both of these conditions occur, `refund_price` is the sum of the lookup price and `cnam` price.
	RefundPrice string `json:"refund_price,omitempty"`
	// Your account balance in EUR after this request.
	RemainingBalance string                     `json:"remaining_balance,omitempty"`
	CurrentCarrier   NiCurrentCarrierProperties `json:"current_carrier,omitempty"`
	OriginalCarrier  NiInitialCarrierProperties `json:"original_carrier,omitempty"`
	// If the user has changed carrier for `number`. The assumed status means that the information supplier has replied to the request but has not said explicitly that the number is ported.
	Ported         string           `json:"ported,omitempty"`
	Roaming        NiRoaming        `json:"roaming,omitempty"`
	CallerIdentity NiCallerIdentity `json:"caller_identity,omitempty"`
	// Shows if all information about a phone number has been returned. Possible values:  Code | Text --- | --- 0 | Success 1 | Partial success - some fields populated 2 | Failed
	LookupOutcome int32 `json:"lookup_outcome,omitempty"`
	// Shows if all information about a phone number has been returned.
	LookupOutcomeMessage string `json:"lookup_outcome_message,omitempty"`
	// Does `number` exist. `unknown` means the number could not be validated. `valid` means the number is valid. `not_valid` means the number is not valid. `inferred_not_valid` means that the number could not be determined as valid or invalid via an external system and the best guess is that the number is invalid. This is applicable to mobile numbers only.
	ValidNumber string `json:"valid_number,omitempty"`
	// Can you call `number` now. This is applicable to mobile numbers only.
	Reachable string `json:"reachable,omitempty"`
}

NiResponseJsonAdvanced Advanced

type NiResponseJsonBasic

type NiResponseJsonBasic struct {
	Status NiBasicStatus `json:"status,omitempty"`
	// The status description of your request.
	StatusMessage string `json:"status_message,omitempty"`
	// The unique identifier for your request. This is a alphanumeric string up to 40 characters.
	RequestId string `json:"request_id,omitempty"`
	// The `number` in your request in international format.
	InternationalFormatNumber string `json:"international_format_number,omitempty"`
	// The `number` in your request in the format used by the country the number belongs to.
	NationalFormatNumber string `json:"national_format_number,omitempty"`
	// Two character country code for `number`. This is in [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
	CountryCode string `json:"country_code,omitempty"`
	// Three character country code for `number`. This is in [ISO 3166-1 alpha-3](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-3) format.
	CountryCodeIso3 string `json:"country_code_iso3,omitempty"`
	// The full name of the country that `number` is registered in.
	CountryName string `json:"country_name,omitempty"`
	// The numeric prefix for the country that `number` is registered in.
	CountryPrefix string `json:"country_prefix,omitempty"`
}

NiResponseJsonBasic struct for NiResponseJsonBasic

type NiResponseJsonStandard

type NiResponseJsonStandard struct {
	Status NiBasicStatus `json:"status,omitempty"`
	// The status description of your request.
	StatusMessage string `json:"status_message,omitempty"`
	// The unique identifier for your request. This is a alphanumeric string up to 40 characters.
	RequestId string `json:"request_id,omitempty"`
	// The `number` in your request in international format.
	InternationalFormatNumber string `json:"international_format_number,omitempty"`
	// The `number` in your request in the format used by the country the number belongs to.
	NationalFormatNumber string `json:"national_format_number,omitempty"`
	// Two character country code for `number`. This is in [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
	CountryCode string `json:"country_code,omitempty"`
	// Three character country code for `number`. This is in [ISO 3166-1 alpha-3](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-3) format.
	CountryCodeIso3 string `json:"country_code_iso3,omitempty"`
	// The full name of the country that `number` is registered in.
	CountryName string `json:"country_name,omitempty"`
	// The numeric prefix for the country that `number` is registered in.
	CountryPrefix string `json:"country_prefix,omitempty"`
	// The amount in EUR charged to your account.
	RequestPrice string `json:"request_price,omitempty"`
	// If there is an internal lookup error, the `refund_price` will reflect the lookup price. If `cnam` is requested for a non-US number the `refund_price` will reflect the `cnam` price. If both of these conditions occur, `refund_price` is the sum of the lookup price and `cnam` price.
	RefundPrice string `json:"refund_price,omitempty"`
	// Your account balance in EUR after this request.
	RemainingBalance string                     `json:"remaining_balance,omitempty"`
	CurrentCarrier   NiCurrentCarrierProperties `json:"current_carrier,omitempty"`
	OriginalCarrier  NiInitialCarrierProperties `json:"original_carrier,omitempty"`
	// If the user has changed carrier for `number`. The assumed status means that the information supplier has replied to the request but has not said explicitly that the number is ported.
	Ported         string           `json:"ported,omitempty"`
	Roaming        NiRoaming        `json:"roaming,omitempty"`
	CallerIdentity NiCallerIdentity `json:"caller_identity,omitempty"`
	// Full name of the person or business who owns the phone number. `unknown` if this information is not available. This parameter is only present if `cnam` had a value of `true` within the request.
	CallerName string `json:"caller_name,omitempty"`
	// Last name of the person who owns the phone number if the owner is an individual. This parameter is only present if `cnam` had a value of `true` within the request.
	LastName string `json:"last_name,omitempty"`
	// First name of the person who owns the phone number if the owner is an individual. This parameter is only present if `cnam` had a value of `true` within the request.
	FirstName string `json:"first_name,omitempty"`
	// The value will be `business` if the owner of a phone number is a business. If the owner is an individual the value will be `consumer`. The value will be `unknown` if this information is not available. This parameter is only present if `cnam` had a value of `true` within the request.
	CallerType string `json:"caller_type,omitempty"`
}

NiResponseJsonStandard struct for NiResponseJsonStandard

type NiResponseJsonStandardAllOf

type NiResponseJsonStandardAllOf struct {
	// The amount in EUR charged to your account.
	RequestPrice string `json:"request_price,omitempty"`
	// If there is an internal lookup error, the `refund_price` will reflect the lookup price. If `cnam` is requested for a non-US number the `refund_price` will reflect the `cnam` price. If both of these conditions occur, `refund_price` is the sum of the lookup price and `cnam` price.
	RefundPrice string `json:"refund_price,omitempty"`
	// Your account balance in EUR after this request.
	RemainingBalance float32                    `json:"remaining_balance,omitempty"`
	CurrentCarrier   NiCurrentCarrierProperties `json:"current_carrier,omitempty"`
	OriginalCarrier  NiInitialCarrierProperties `json:"original_carrier,omitempty"`
	// If the user has changed carrier for `number`. The assumed status means that the information supplier has replied to the request but has not said explicitly that the number is ported.
	Ported         string           `json:"ported,omitempty"`
	Roaming        NiRoaming        `json:"roaming,omitempty"`
	CallerIdentity NiCallerIdentity `json:"caller_identity,omitempty"`
	// Full name of the person or business who owns the phone number. `unknown` if this information is not available. This parameter is only present if `cnam` had a value of `true` within the request.
	CallerName string `json:"caller_name,omitempty"`
	// Last name of the person who owns the phone number if the owner is an individual. This parameter is only present if `cnam` had a value of `true` within the request.
	LastName string `json:"last_name,omitempty"`
	// First name of the person who owns the phone number if the owner is an individual. This parameter is only present if `cnam` had a value of `true` within the request.
	FirstName string `json:"first_name,omitempty"`
	// The value will be `business` if the owner of a phone number is a business. If the owner is an individual the value will be `consumer`. The value will be `unknown` if this information is not available. This parameter is only present if `cnam` had a value of `true` within the request.
	CallerType string `json:"caller_type,omitempty"`
}

NiResponseJsonStandardAllOf struct for NiResponseJsonStandardAllOf

type NiRoaming

type NiRoaming struct {
	// Is `number` outside its home carrier network.
	Status string `json:"status,omitempty"`
	// If `number` is `roaming`, this is the [code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) of the country `number` is roaming in.
	RoamingCountryCode string `json:"roaming_country_code,omitempty"`
	// If `number` is `roaming`, this is the id of the carrier network `number` is roaming in.
	RoamingNetworkCode string `json:"roaming_network_code,omitempty"`
	// If `number` is `roaming`, this is the name of the carrier network `number` is roaming in.
	RoamingNetworkName string `json:"roaming_network_name,omitempty"`
}

NiRoaming Information about the roaming status for `number`. This is applicable to mobile numbers only.

type NiStandardAdvancedStatus

type NiStandardAdvancedStatus int32

NiStandardAdvancedStatus Code | Text -- | -- 0 | Success - request accepted for delivery by Nexmo. 1 | Busy - you have made more requests in the last second than are permitted by your Nexmo account. Please retry. 3 | Invalid - your request is incomplete and missing some mandatory parameters. 4 | Invalid credentials - the _api_key_ or _api_secret_ you supplied is either not valid or has been disabled. 5 | Internal Error - the format of the recipient address is not valid. 9 | Partner quota exceeded - your Nexmo account does not have sufficient credit to process this request. 19 | Facility Not Allowed - your request makes use of a facility that is not enabled on your account. 43, 44, 45 | Live mobile lookup not returned. Not all return parameters are available. 999 | Request unparseable.

type ServerConfiguration

type ServerConfiguration struct {
	Url         string
	Description string
	Variables   map[string]ServerVariable
}

ServerConfiguration stores the information about a server

type ServerVariable

type ServerVariable struct {
	Description  string
	DefaultValue string
	EnumValues   []string
}

ServerVariable stores the information about a server variable

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL