digitaluapi

<back to all web services

CustomersLookup

Requires Authentication
Requires any of the roles:Client, Admin, Partner
The following routes are available for this service:
GET/customers
import datetime
import decimal
from marshmallow.fields import *
from servicestack import *
from typing import *
from dataclasses import dataclass, field
from dataclasses_json import dataclass_json, LetterCase, Undefined, config
from enum import Enum, IntEnum


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class CustomersLookup:
    tenants_id: int = 0
    user_auth_id: Optional[int] = None
    segments_id: int = 0
    companies_id: Optional[int] = None
    currencies_id: Optional[int] = None
    address: Optional[str] = None
    age: Optional[int] = None
    city: Optional[str] = None
    contact_number: Optional[str] = None
    email: Optional[str] = None
    ethnic_group: Optional[str] = None
    first_name: Optional[str] = None
    gender: Optional[str] = None
    home_language: Optional[str] = None
    id_number: Optional[str] = None
    last_name: Optional[str] = None
    postal_code: Optional[str] = None
    region: Optional[str] = None
    suburb: Optional[str] = None
    unique_identifier: Optional[str] = None

Python CustomersLookup DTOs

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

HTTP + JSV

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

GET /customers HTTP/1.1 
Host: duengageapi.uat.scadsoftware.com 
Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

[
	{
		TenantsId: 0,
		UserAuthId: 0,
		SegmentsId: 0,
		CompaniesId: 0,
		CurrenciesId: 0,
		Address: String,
		Age: 0,
		City: String,
		ContactNumber: String,
		Email: String,
		EthnicGroup: String,
		FirstName: String,
		Gender: String,
		HomeLanguage: String,
		IdNumber: String,
		LastName: String,
		PostalCode: String,
		Region: String,
		Suburb: String,
		UniqueIdentifier: String,
		ResponseStatus: 
		{
			ErrorCode: String,
			Message: String,
			StackTrace: String,
			Errors: 
			[
				{
					ErrorCode: String,
					FieldName: String,
					Message: String,
					Meta: 
					{
						String: String
					}
				}
			],
			Meta: 
			{
				String: String
			}
		}
	}
]