| Requires the role: | Admin | Requires the permission: | ReadData |
| GET | /stig/history |
|---|
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 LocalizedMessage:
is_: Optional[str] = field(metadata=config(field_name='is'), default=None)
en: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class StigHistoryEntry:
id: Optional[int] = None
kind: Optional[str] = None
label: Optional[LocalizedMessage] = None
amount: Optional[int] = None
affects_balance: Optional[bool] = None
event_id: Optional[int] = None
event_name: Optional[str] = None
event_time_utc: Optional[datetime.datetime] = None
owner_id: Optional[int] = None
owner_name: Optional[str] = None
ticket_id: Optional[int] = None
order_reference: Optional[str] = None
source_amount_minor: Optional[int] = None
multiplier_basis_points: Optional[int] = None
campaign_code: Optional[str] = None
status: Optional[str] = None
created_utc: Optional[datetime.datetime] = None
note: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class StigHistoryResult:
full_phone_number: Optional[str] = None
known: Optional[bool] = None
items: Optional[List[StigHistoryEntry]] = None
total_count: Optional[int] = None
skip: Optional[int] = None
take: Optional[int] = None
status_code: Optional[int] = None
message: Optional[str] = None
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class StigHistoryRequest:
full_phone_number: Optional[str] = None
skip: Optional[int] = None
take: Optional[int] = None
include_holds: Optional[bool] = None
Python StigHistoryRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
GET /stig/history HTTP/1.1 Host: stubbur-app.azurewebsites.net Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
fullPhoneNumber: String,
known: False,
items:
[
{
id: 0,
kind: String,
label:
{
is: String,
en: String
},
amount: 0,
affectsBalance: False,
eventId: 0,
eventName: String,
eventTimeUtc: 0001-01-01,
ownerId: 0,
ownerName: String,
ticketId: 0,
orderReference: String,
sourceAmountMinor: 0,
multiplierBasisPoints: 0,
campaignCode: String,
status: String,
createdUtc: 0001-01-01,
note: String
}
],
totalCount: 0,
skip: 0,
take: 0,
statusCode: 0,
message: String
}