BokaMera.API.Host

<back to all web services

GetRebateCodeStatus

Requires Authentication
Requires any of the roles:bookingsupplier-administrator-write, bookingsupplier-administrator-read, superadmin
The following routes are available for this service:
GET/rebatecodes/statusesGet RebateCode statusesGet RebateCode statuses
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 RebateCodeStatusItem:
    id: int = 0
    rebate_code_status_name: Optional[str] = None
    rebate_code_status_description: Optional[str] = None


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class RebateCodeStatusResponse:
    response_status: Optional[ResponseStatus] = None
    rebate_code_status_items: Optional[List[RebateCodeStatusItem]] = None


# @ApiResponse(Description="You were unauthorized to call this service", StatusCode=401)
# @ValidateRequest(Validator="IsAuthenticated")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class GetRebateCodeStatus:
    # @ApiMember(Description="RebateCodeId")
    id: Optional[int] = None
    """
    RebateCodeId
    """

Python GetRebateCodeStatus 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 /rebatecodes/statuses HTTP/1.1 
Host: api.bokamera.se 
Accept: text/csv
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}},"RebateCodeStatusItems":[{"Id":0,"RebateCodeStatusName":"String","RebateCodeStatusDescription":"String"}]}