NAV

<back to all web services

RegionGetList

DomainAPI|Regions
The following routes are available for this service:
GET/regions
Imports System
Imports System.Collections
Imports System.Collections.Generic
Imports System.Runtime.Serialization
Imports ServiceStack
Imports ServiceStack.DataAnnotations
Imports Nxnw.Adc.CountryCulture.ServiceModel
Imports Nxnw.Adc.Common.ServiceModel

Namespace Global

    Namespace Nxnw.Adc.Common.ServiceModel

        Public Partial Class GetListResponse(Of TEntity)
            Public Sub New()
                Items = New List(Of TEntity)
            End Sub

            Public Overridable Property Items As List(Of TEntity)
            Public Overridable Property ResponseStatus As ResponseStatus
        End Class
    End Namespace

    Namespace Nxnw.Adc.CountryCulture.ServiceModel

        Public Partial Class RegionGetList
            Implements IGet
        End Class

        Public Partial Class RegionGetListResponse
            Inherits GetListResponse(Of RegionViewModel)
        End Class

        Public Partial Class RegionViewModel
            Public Overridable Property RegionId As String
            Public Overridable Property RegionDescription As String
        End Class
    End Namespace
End Namespace

VB.NET RegionGetList DTOs

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

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

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

GET /regions HTTP/1.1 
Host: extensions.avon.ca 
Accept: application/json
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"items":[{"regionId":"String","regionDescription":"String"}],"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}}}