Mews · Schema

Billing automation

HospitalityHotelsPMSProperty Management

Properties

Name Type Description
Id string Unique identifier of the billing automation.
EnterpriseId string Unique identifier of the enterprise.
Name string Name of the billing automation.
Description string Description of the billing automation.
CompaniesWithRelations array List of companies with relations to the billing automation.
Prepayment object Type of prepayment. All (All) Prepaid (Prepaid)
AssignmentTargetType object Type of target company and customer assignment behavior. CompanyAsDetails (The company will be the associated account in the resulting routed bill, and the customer is the owner.) CompanyAsOwner (The
TriggerType object Trigger type of billing automation. Continuous (Billing automation is continuously triggered by reservation actions, such as creation, updates, and rebates.) Recurring (Billing automation is executed
BillAggregationType object Type of bill aggregation. OnePerReservation (Create a separate bill for each reservation.) AggregateByCustomer (Create a separate bill for each reservation owner.) AggregateAll (Group all moved items
CreatedUtc string Creation date and time of the billing automation in UTC timezone in ISO 8601 format.
UpdatedUtc string Last update date and time of the billing automation in UTC timezone in ISO 8601 format.
CreatorProfileId string Unique identifier of the user who created the billing automation.
UpdaterProfileId string Unique identifier of the user who last updated the billing automation.
ProcessingStartOffset string Processing start offset. Applicable only if the billing automation `TriggerType` is set to `Reccuring`.
OrderItemConsumptionPeriod object Specifies the type of order item consumption period for the billing automation. This value is applicable only when the `TriggerType` is set to `Reccuring`. MonthBefore (Only items with a consumption d
Assignments array List of billing automation assignments.
View JSON Schema on GitHub

JSON Schema

mews-billingautomation-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "#/components/schemas/BillingAutomation",
  "title": "Billing automation",
  "required": [
    "AssignmentTargetType",
    "BillAggregationType",
    "CompaniesWithRelations",
    "CreatedUtc",
    "CreatorProfileId",
    "EnterpriseId",
    "Id",
    "Name",
    "Prepayment",
    "TriggerType",
    "UpdatedUtc",
    "UpdaterProfileId"
  ],
  "type": "object",
  "properties": {
    "Id": {
      "type": "string",
      "description": "Unique identifier of the billing automation.",
      "format": "uuid"
    },
    "EnterpriseId": {
      "type": "string",
      "description": "Unique identifier of the enterprise.",
      "format": "uuid"
    },
    "Name": {
      "minLength": 1,
      "type": "string",
      "description": "Name of the billing automation."
    },
    "Description": {
      "type": "string",
      "description": "Description of the billing automation.",
      "nullable": true
    },
    "CompaniesWithRelations": {
      "maxItems": 1000,
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/CompanyWithBillingAutomationRelation"
      },
      "description": "List of companies with relations to the billing automation."
    },
    "Prepayment": {
      "title": "Billing automation prepayment type",
      "allOf": [
        {
          "$ref": "#/components/schemas/BillingAutomationPrepaymentEnum"
        }
      ],
      "description": "Type of prepayment.\n\nAll (All)\n\nPrepaid (Prepaid)",
      "x-enumNames": [
        "All",
        "Prepaid"
      ],
      "x-enumDescriptions": [
        "All",
        "Prepaid"
      ]
    },
    "AssignmentTargetType": {
      "title": "Billing automation assignment target type",
      "allOf": [
        {
          "$ref": "#/components/schemas/BillingAutomationAssignmentTargetTypeEnum"
        }
      ],
      "description": "Type of target company and customer assignment behavior.\n\nCompanyAsDetails (The company will be the associated account in the resulting routed bill, and the customer is the owner.)\n\nCompanyAsOwner (The company will be the owner in the resulting routed bill, and the customer might be the associated account.)\n\nNoCompany (The customer will be owner of the bill.)",
      "x-enumNames": [
        "CompanyAsDetails",
        "CompanyAsOwner",
        "NoCompany"
      ],
      "x-enumDescriptions": [
        "The company will be the associated account in the resulting routed bill, and the customer is the owner.",
        "The company will be the owner in the resulting routed bill, and the customer might be the associated account.",
        "The customer will be owner of the bill."
      ]
    },
    "TriggerType": {
      "title": "Billing automation trigger type",
      "allOf": [
        {
          "$ref": "#/components/schemas/BillingAutomationTriggerTypeEnum"
        }
      ],
      "description": "Trigger type of billing automation.\n\nContinuous (Billing automation is continuously triggered by reservation actions, such as creation, updates, and rebates.)\n\nRecurring (Billing automation is executed monthly.)\n\nLegacy (Billing automation is executed on reservation creation only. Items added later are not transfered to any bill.)",
      "x-enumNames": [
        "Continuous",
        "Recurring",
        "Legacy"
      ],
      "x-enumDescriptions": [
        "Billing automation is continuously triggered by reservation actions, such as creation, updates, and rebates.",
        "Billing automation is executed monthly.",
        "Billing automation is executed on reservation creation only. Items added later are not transfered to any bill."
      ]
    },
    "BillAggregationType": {
      "title": "Billing automation bill aggregation type",
      "allOf": [
        {
          "$ref": "#/components/schemas/BillingAutomationBillAggregationTypeEnum"
        }
      ],
      "description": "Type of bill aggregation.\n\nOnePerReservation (Create a separate bill for each reservation.)\n\nAggregateByCustomer (Create a separate bill for each reservation owner.)\n\nAggregateAll (Group all moved items on one bill.)\n\nAggregatePerReservationGroup (Create a separate bill for each reservation group.)",
      "x-enumNames": [
        "OnePerReservation",
        "AggregateByCustomer",
        "AggregateAll",
        "AggregatePerReservationGroup"
      ],
      "x-enumDescriptions": [
        "Create a separate bill for each reservation.",
        "Create a separate bill for each reservation owner.",
        "Group all moved items on one bill.",
        "Create a separate bill for each reservation group."
      ]
    },
    "CreatedUtc": {
      "minLength": 1,
      "type": "string",
      "description": "Creation date and time of the billing automation in UTC timezone in ISO 8601 format.",
      "format": "date-time"
    },
    "UpdatedUtc": {
      "minLength": 1,
      "type": "string",
      "description": "Last update date and time of the billing automation in UTC timezone in ISO 8601 format.",
      "format": "date-time"
    },
    "CreatorProfileId": {
      "type": "string",
      "description": "Unique identifier of the user who created the billing automation.",
      "format": "uuid"
    },
    "UpdaterProfileId": {
      "type": "string",
      "description": "Unique identifier of the user who last updated the billing automation.",
      "format": "uuid"
    },
    "ProcessingStartOffset": {
      "type": "string",
      "description": "Processing start offset. Applicable only if the billing automation `TriggerType` is set to `Reccuring`.",
      "nullable": true
    },
    "OrderItemConsumptionPeriod": {
      "allOf": [
        {
          "$ref": "#/components/schemas/BillingAutomationOrderItemConsumptionPeriodTypeEnum"
        }
      ],
      "description": "Specifies the type of order item consumption period for the billing automation. This value is applicable only when the `TriggerType` is set to `Reccuring`.\n\nMonthBefore (Only items with a consumption date within the previous month will be routed.)\n\nSameMonthAndMonthBefore (Only items with a consumption date within this and the previous month will be routed.)\n\nSameMonth (Only items with a consumption date within this month will be routed.)\n\nSameMonthAndMonthAfter (Only items with a consumption date within this and the next month will be routed.)\n\nMonthAfter (Only items with a consumption date within the next month will be routed.)",
      "nullable": true
    },
    "Assignments": {
      "maxItems": 20,
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/BillingAutomationAssignment"
      },
      "description": "List of billing automation assignments.",
      "nullable": true
    }
  },
  "additionalProperties": false,
  "x-schema-id": "BillingAutomation"
}