{
  "resourceType": "StructureDefinition",
  "url": "https://api-erp.kamsoft.pl/ns/StructureDefinition/InvoicePosition",
  "name": "InvoicePosition",
  "version": "1.0.0",
  "title": "Pozycja faktury (InvoicePosition)",
  "description": "Wiersz faktury — zagnieżdżony w Invoice.lines; IG Invoice-Canonic-Model.",
  "kind": "complex-type",
  "abstract": false,
  "type": "InvoicePosition",
  "snapshot": {
    "element": [
      {
        "path": "InvoicePosition.positionNo",
        "min": 1,
        "max": "1",
        "short": "Numer wiersza",
        "definition": "Liczba porządkowa od 1.",
        "type": [
          {
            "code": "Int32"
          }
        ]
      },
      {
        "path": "InvoicePosition.description",
        "min": 0,
        "max": "1",
        "short": "Opis towaru/usługi",
        "type": [
          {
            "code": "String"
          }
        ]
      },
      {
        "path": "InvoicePosition.quantity",
        "min": 0,
        "max": "1",
        "short": "Ilość i jednostka",
        "definition": "Typ Quantity — ilość + jednostka miary.",
        "type": [
          {
            "code": "Quantity"
          }
        ]
      },
      {
        "path": "InvoicePosition.unitPriceNet",
        "min": 0,
        "max": "1",
        "short": "Cena jednostkowa netto",
        "type": [
          {
            "code": "Money"
          }
        ]
      },
      {
        "path": "InvoicePosition.netAmount",
        "min": 1,
        "max": "1",
        "short": "Wartość netto pozycji",
        "type": [
          {
            "code": "Money"
          }
        ]
      },
      {
        "path": "InvoicePosition.vatRate",
        "min": 0,
        "max": "1",
        "short": "Stawka VAT",
        "type": [
          {
            "code": "CodeableConcept"
          }
        ],
        "binding": {
          "valueSet": "https://api-erp.kamsoft.pl/ns/ValueSet/VatRate-PL"
        }
      },
      {
        "path": "InvoicePosition.vatAmount",
        "min": 0,
        "max": "1",
        "short": "Kwota VAT pozycji",
        "type": [
          {
            "code": "Money"
          }
        ]
      },
      {
        "path": "InvoicePosition.exciseAmount",
        "min": 0,
        "max": "1",
        "short": "Kwota akcyzy pozycji",
        "type": [
          {
            "code": "Money"
          }
        ]
      },
      {
        "path": "InvoicePosition.exciseType",
        "min": 0,
        "max": "1",
        "short": "Rodzaj / kategoria akcyzy",
        "type": [
          {
            "code": "CodeableConcept"
          }
        ],
        "binding": {
          "valueSet": "https://api-erp.kamsoft.pl/ns/excise-type"
        }
      },
      {
        "path": "InvoicePosition.productReference",
        "min": 0,
        "max": "1",
        "short": "Referencja do towaru/usługi",
        "definition": "ProductDefinition lub Product.",
        "type": [
          {
            "code": "Reference"
          }
        ]
      },
      {
        "path": "InvoicePosition.discount",
        "min": 0,
        "max": "1",
        "short": "Rabat (kwota)",
        "type": [
          {
            "code": "Money"
          }
        ]
      },
      {
        "path": "InvoicePosition.discountCodeableConcept",
        "min": 0,
        "max": "1",
        "short": "Rabat (kodowanie CodeableConcept)",
        "type": [
          {
            "code": "CodeableConcept"
          }
        ]
      }
    ]
  }
}