ExpenseType

URL

https://api.primatime.com/v1/time/expenseTypes

Properties

Name Type Access Required Description
createdAt Date read only no Date of creation.
displayName String read only no Describes an object in human readable form.
id String read write no Unique object identifier.
isActive Boolean read write YES Whether the expense is active.
isBillable Boolean read write YES Whether the expense is billable.
name String read write YES String that describes the expense type.
trashItem TrashItem read write no Informs whether an object is in the trash. An object is in the trash if a trash item was specified.
unitName String read write no Unit name.
unitPrice Double read write YES Price per unit.
updatedAt Date read only no Last modified date.
version Long read write no Object version number.

Metadata

{
    "type" : "ExpenseType",
    "path" : "/v1/time/expenseTypes",
    "fields" : [
        {
            "type" : "Date",
            "name" : "createdAt",
            "description" : "Date of creation.",
            "access" : "READ_ONLY"
        },
        {
            "type" : "String",
            "name" : "displayName",
            "description" : "Describes an object in human readable form.",
            "access" : "READ_ONLY"
        },
        {
            "type" : "String",
            "name" : "id",
            "description" : "Unique object identifier.",
            "access" : "READ_WRITE",
            "constraints" : [
                {
                    "type" : "Pattern",
                    "details" : "regexp [0-9a-f]{8}(?:-[0-9a-f]{4}){3}-[0-9a-f]{12}"
                },
                {
                    "type" : "NotNull"
                }
            ]
        },
        {
            "type" : "Boolean",
            "name" : "isActive",
            "description" : "Whether the expense is active.",
            "access" : "READ_WRITE",
            "constraints" : [
                {
                    "type" : "NotNull"
                }
            ]
        },
        {
            "type" : "Boolean",
            "name" : "isBillable",
            "description" : "Whether the expense is billable.",
            "access" : "READ_WRITE",
            "constraints" : [
                {
                    "type" : "NotNull"
                }
            ]
        },
        {
            "type" : "String",
            "name" : "name",
            "description" : "String that describes the expense type.",
            "access" : "READ_WRITE",
            "constraints" : [
                {
                    "type" : "NotNull"
                }
            ]
        },
        {
            "type" : "TrashItem",
            "path" : "/v1/trash",
            "name" : "trashItem",
            "description" : "Informs whether an object is in the trash. An object is in the trash if a trash item was specified.",
            "access" : "READ_WRITE"
        },
        {
            "type" : "String",
            "name" : "unitName",
            "description" : "Unit name.",
            "access" : "READ_WRITE"
        },
        {
            "type" : "Double",
            "name" : "unitPrice",
            "description" : "Price per unit.",
            "access" : "READ_WRITE",
            "constraints" : [
                {
                    "type" : "NotNull"
                }
            ]
        },
        {
            "type" : "Date",
            "name" : "updatedAt",
            "description" : "Last modified date.",
            "access" : "READ_ONLY"
        },
        {
            "type" : "Long",
            "name" : "version",
            "description" : "Object version number.",
            "access" : "READ_WRITE"
        }
    ],
    "cascades" : [
        {
            "cascadeType" : "REMOVE",
            "objectTypes" : [
                "TrashItem"
            ]
        }
    ]
}

Dummy data

{
    "id" : "d209f605-b586-4f79-b34e-c0775b143347",
    "createdAt" : "/Date(1651048107020)/",
    "updatedAt" : "/Date(1651097307020)/",
    "version" : 0,
    "name" : "Gas",
    "unitPrice" : 125.0,
    "unitName" : "km",
    "isActive" : true,
    "isBillable" : true,
    "displayName" : "Gas"
}

results matching ""

    No results matching ""