Evo Voice

<back to all web services

SearchPhoneNumbers

Search for phone numbers

Requires Authentication
Requires any of the roles:SystemAdministrator, Manager, Customer
The following routes are available for this service:
GET/endpoints/phone-numbers/search
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using Voice.Api.Endpoints;

namespace Voice.Api.Endpoints
{
    ///<summary>
    ///Search for phone numbers
    ///</summary>
    [Api(Description="Search for phone numbers")]
    public partial class SearchPhoneNumbers
        : IGet
    {
        ///<summary>
        ///The account you are searching for
        ///</summary>
        [ApiMember(Description="The account you are searching for")]
        public virtual string AccountId { get; set; }

        ///<summary>
        ///The area code
        ///</summary>
        [ApiMember(Description="The area code")]
        public virtual string AreaCode { get; set; }

        ///<summary>
        ///The country code you are searching for
        ///</summary>
        [ApiMember(Description="The country code you are searching for")]
        public virtual string CountryCode { get; set; }

        ///<summary>
        ///The postal code you are searching for
        ///</summary>
        [ApiMember(Description="The postal code you are searching for")]
        public virtual string PostalCode { get; set; }

        ///<summary>
        ///The distance from the specified postal code (default is 100)
        ///</summary>
        [ApiMember(Description="The distance from the specified postal code (default is 100)")]
        public virtual int? Distance { get; set; }

        ///<summary>
        ///Search for fax numbers
        ///</summary>
        [ApiMember(Description="Search for fax numbers")]
        public virtual bool IsFaxNumber { get; set; }

        ///<summary>
        ///Contains specific digits
        ///</summary>
        [ApiMember(Description="Contains specific digits")]
        public virtual string Contains { get; set; }
    }

}

C# SearchPhoneNumbers DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv

HTTP + CSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

GET /endpoints/phone-numbers/search HTTP/1.1 
Host: evovoice.io 
Accept: text/csv
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

[{"phoneNumber":"String"}]