Manage LSR orders
The LsrOrders endpoint is used to create, modify, and monitor API requests to remove telephone numbers from the Bandwidth network. This API call is intended for use by carriers that want to automate the "Port-out" process with Bandwidth, rather than manually request the removal or "port-out" of each telephone number via a GUI or a Ticket.
This API call uses an asynchronous model that is common in the Bandwidth Dashboard API, where an "order" is created that is then subsequently used to track the progress of the request to completion. This in somewhat analogous to the "laundry ticket" model, where the initial transaction is the submission of the laundry and the receipt of a ticket, and all other steps in the overall transaction use the identifier on the ticket to monitor and manage the transaction.
In this case a POST is made to the /lsrorders resource that describes the request to port out the number. If the POST has no syntactic errors, such as a telephone number with less than 10 digits, an ID will be returned that is used to monitor and manage the port-out request. The POST returns both a descriptive payload that reflects the request and includes the identifier, as well as a Location header that contains a valid GET API call that can be used to retrieve the current state of the LSR / Port-out request. In general the flow of events is much like...
The above notifications continue until the LSR is complete or cancelled. There is a complete list of elements in payload of the POSTed request below in the documentation of the POST, but in summary the LSR request includes:
- a list of telephone numbers
- information about the subscriber
- tracking information such as a PON and a Customer Order ID
- winning carrier information such as the SPID
- date information This API supports GET for retrieving order detail and status information, POST for creating a new LSR Order, and PUT for changing the details of an LSR in flight. PUT is also used to cancel an order, by changing the order status field to cancelled. This is the only case where the status can be changed, and when this is done, all other fields are left as they were prior to the cancellation.
The payload fields are described below:
Field | Description |
---|---|
Pon | The Pon is customer specified order indentifier field. Allowed alphanumeric and "#","-","_". Up to 25 characters long. (required) |
CustomerOrderId | The CustomerOrderId is customer specified order indentifier field. Allowed alphanumeric, spaces and dashes. Up to 40 characters long. (optional) |
SPID | Identifier used in porting process. If account is no multi-SPID option - default with account value, otherwise value is required. Up to 4 characters long. (required |
BillingTelephoneNumber | Non-tollfree 10 digit phone number (optional) |
RequestedFocDate | optional (next day if not specified) |
SubscriberType | Subscriber type. BUSINESS |
BusinessName | Subscriber business name for BUSINESS SubscriberType. Up to 25 characters long. (required BusinessName or LastName) |
LastName | Subscriber last name for RESEDENTIAL SubscriberType. Up to 25 characters long. (required BusinessName or LastName) |
FirstName | Subscriber first name for RESEDENTIAL SubscriberType. Up to 25 characters long. (optional) |
MiddleInitial | Subscriber middle initial for RESEDENTIAL SubscriberType. 1 character (optional) |
AccountNumber | AccountNumber. Alphanumeric, up to 32 characters. (optional) |
PinNumber | PinNumber. Alphanumeric, up to 10 characters. (optional) |
AuthorizingPerson | AuthorizingPerson. Alphanumeric, up to 100 characters (required) |
HousePrefix | HousePrefix. Alphanumeric, up to 6 characters |
HouseNumber | HouseNumber. Alphanumeric, up to 45 characters (required) |
HouseSuffix | HouseSuffix. Alphanumeric, up to 45 characters |
PreDirectional | PreDirectional. Alphanumeric, up to 2 characters |
StreetName | StreetName. Alphanumeric, up to 200 characters (required) |
StreetSuffix | StreetSuffix. Alphanumeric, up to 45 characters |
PostDirectional | PostDirectional. Alphanumeric, up to 2 characters |
AddressLine2 | AddressLine2. Alphanumeric, up to 200 characters |
County | County. Alphanumeric, up to 45 characters |
City | City. Alphanumeric, up to 100 characters (required) |
StateCode | StateCode. Alphanumeric, 2 characters (required) |
Zip | Zip code. Allowed formats: 5 numbers, 5+4 or Canadian (required) |
ListOfTelephoneNumbers | List of tns to be processed (required) |
ERRORS There are a number of errors that can happen at various stages of the process. These are listed here for convenience, and can be found in the error reference documentation here.
Error code | Error message | Appearance |
---|---|---|
5008 | All telephone numbers specified are invalid | POST |
7104 | Subscriber information is required | POST/PUT |
7105 | The subscriber name is required | POST/PUT |
7107 | The service address is required | POST/PUT |
7108 | The service address house number is required | POST/PUT |
7109 | The service address street name is required | POST/PUT |
7110 | The service address city is required | POST/PUT |
7111 | The service address state code is required | POST/PUT |
7112 | The service address zip code is required | POST/PUT |
7120 | The PON is required | POST |
7203 | The billing telephone number (BTN) is invalid | POST/PUT |
7208 | The requested FOC date cannot be in the past | POST/PUT |
7214 | ZIP code is invalid | POST/PUT |
7318 | Customer order ID is invalid. Only alphanumeric values, dashes and spaces are allowed. Max length is 40 characters. | POST/PUT |
7324 | The business name is too long. The business name should not be longer than 25 characters. | POST/PUT |
7354 | Middle initial is too long. Middle initial should not be longer than 1 character. | POST/PUT |
7355 | First name is too long. First name should not be longer than 25 characters. | POST/PUT |
7356 | Last name is too long. Last name should not be longer than 25 characters. | POST/PUT |
7395 | Unsupported state code %s. | POST/PUT |
7510 | Required Account Code missing | PROCESSING |
7511 | Invalid Account Code | PROCESSING |
7512 | Required PIN missing | PROCESSING |
7513 | PIN Invalid | PROCESSING |
7514 | Required ZIP Code missing | PROCESSING |
7515 | Invalid ZIP Code | PROCESSING |
7516 | Telephone Number not recognized or invalid for this account | PROCESSING |
7517 | Too many Telephone numbers in this request | PROCESSING |
7518 | Telephone Number Not Active | PROCESSING |
7519 | Customer info does not match | PROCESSING |
7598 | Invalid Request | PROCESSING |
7599 | Fatal Error in Processing | PROCESSING |
7999 | An internal error has occurred. Please contact support if this issue is not resolved in 1 business day | PROCESSING |
13522 | The count of telephone numbers in order exceeds the maximum size of %d | POST |
17000 | Lsr submission order payload required. | POST/PUT |
17002 | Order contains invalid tns %s. | POST |
17003 | Order contains empty tn list or its not present. | POST |
17004 | Incorrect pon specified. It must be up to 25 character long and could not contain special characters other than -_# | POST |
17005 | Toll-free telephone numbers can not be present in the LSR order. | POST |
17006 | Account number is incorrect. It should be alphanumeric and no more than 32 characters long. | POST/PUT |
17007 | Pin number is incorrect. It should be alphanumeric and no more than 10 characters long. | POST/PUT |
17008 | An internal error has occurred. Please contact support if this issue is not resolved in 1 business day | PROCESSING |
17009 | Lsr order contain duplicate telephone numbers %s | POST |
17010 | Business name is required for business SubscriberType. | POST/PUT |
17011 | Last name should be empty for business SubscriberType. | POST/PUT |
17012 | Last name is required for residential SubscriberType. | POST/PUT |
17013 | Requested date format incorrect. Date should be in yyyy-mm-dd format. (example 2015-03-24). | POST/PUT |
17017 | Lsr order failed account SPID not configured. | PUT/PROCESSING |
17018 | Lsr order will be cancelled. All other submitted changes are ignored. | PUT/PROCESSING |
17019 | Requested FOC date cannot be on holiday or weekend. | POST/PUT |
17020 | Account SPID [%s] does not match with SPID specified in the Lsr order [%s]. | POST/PUT |
17021 | Incorrect SPID [%s] specified in the order. It should be alphanumeric and no more than 4 characters long. | POST/PUT |
17022 | Account %d requires a SPID to be provided with each order. | POST/PUT |
17023 | The authorizing person contact is required for lsr orders. | POST/PUT |
17024 | The authorizing person contact is too long. It should be not longer than %s characters. | POST/PUT |
17025 | %s field%s cannot be modified. | PUT |
17025 | OrderStatus cannot be changed to %s. Only cancelled value allowed. | PUT |
17027 | Account %d has no configured SPID. Please contact support for further assistance. | POST/PUT |
17028 | Minimum FOC date for a port of greater than %1$d telephone numbers is %2$d days | POST/PUT |
17029 | Can't modify LSR order, because it contains ported numbers. | PROCESSING |
17030 | LSR order completion failed, some numbers are not activated: %s. | PROCESSING |
17031 | Order was failed, because some telephone numbers have empty SPID [%s] | PROCESSING |
17032 | The Specified PON is already present in our system. Please provide an alternative. | POST |
17033 | The PON specified in the LSR order overlaps with existing order. Please resubmit the order with another PON. | POST |
17034 | OverrideValidation flag can be supped only in EXCEPTION status. | PUT |
17035 | Supp is not allowed for this LSR. Please contact support if this issue is not resolved in 1 business day. | PUT |
- POST - errors occur during LSR creation.
- PUT - errors occur during LSR supp/cancel.
- PROCESSING - errors occur while LSR processing. These errors are persistent and can be retrieved using GET requests (ex. by LSR ID).
* Error messages can differ from described depending on context of occurrence.