<?xml version="1.0" encoding="windows-1250"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
	<xs:annotation>
		<xs:documentation>
			Pliki XML zgodne z tym schematem zawierają informacje o dokumentach księgowych, ich dekretacji oraz uregulowaniu.
			Są stosowane do przenoszenie danych z programu fakturującego do Puzzli, migracji danych z innych programów finansowo-księgowych, przenoszenia danych między różnymi firmami i miesiącami w Puzzlach.
			Data publikacji: 2025-09-29.
		</xs:documentation>
	</xs:annotation>

<xs:simpleType name="nie_tak">
	<xs:restriction base="xs:string">
		<xs:enumeration value="nie"/>
		<xs:enumeration value="tak"/>
	</xs:restriction>
</xs:simpleType>

<xs:simpleType name="flag">
	<xs:restriction base="xs:byte">
		<xs:enumeration value="1"/>
	</xs:restriction>
</xs:simpleType>

<xs:simpleType name="money">
	<xs:annotation>
		<xs:documentation>
			Kwota w walucie.
		</xs:documentation>
	</xs:annotation>
	<xs:restriction base="xs:decimal">
		<xs:fractionDigits value="2"/>
	</xs:restriction>
</xs:simpleType>

<xs:simpleType name="waluta_t">
	<xs:annotation>
		<xs:documentation>
			3-literowy symbol waluty - np. "EUR" lub "USD"
		</xs:documentation>
	</xs:annotation>
	<xs:restriction base="xs:string">
		<xs:pattern value="[A-Z][A-Z][A-Z]"/>
	</xs:restriction>
</xs:simpleType>

<xs:simpleType name="kurs_t">
	<xs:annotation>
		<xs:documentation>
			Kurs waluty. Może mieć max. 8 cyfr nie licząc początkowych i końcowych zer, i max. 9 miejsc po przecinku. Uwaga: poniższa definicja nie uwzględnia pierwszego z tych ograniczeń.
		</xs:documentation>
	</xs:annotation>
    <xs:restriction base="xs:decimal">
        <xs:fractionDigits value="9"/>
		<xs:minExclusive value="0"/>
		<xs:maxInclusive value="999999"/>
		<xs:totalDigits value="10"/>
    </xs:restriction>
</xs:simpleType>

<xs:element name="paczka">
	<xs:annotation>
		<xs:documentation>
			Paczka zawiera dane z dokumentów z jednego miesiąca, ale nie muszą to być wszystkie dokumenty z tego miesiąca.
			Ponieważ dokumenty z pliku XML są podczas importu przedstawiane użytkownikowi do selekcji w takiej kolejności, w jakiej są zapisane w pliku, więc - dla wygody użytkownika - dobrze by były uporządkowane chronologicznie. Brak takiego porządku nie ma jednak wpływu na poprawność importu.
			Dokumenty nie-sprzedaży (zakupy, wydatki itp.) z jednego dnia są po zaimportowaniu uporządkowane tak jak w pliku XML. Zatem ich kolejność w pliku jest istotna.
			Dokumenty, które nie pasują do firmy, do której są importowane - np. są zadekretowane tylko do rejestru VAT w przypadku firmy nie będącej podatnikiem VAT, lub są zadekretowane jako wydatek w przypadku firmy ryczałtowej - są pomijane przy imporcie.
		</xs:documentation>
	</xs:annotation>
	<xs:complexType>
		<xs:sequence>
			<xs:element name="dokument" maxOccurs="unbounded">
				<xs:complexType>
					<xs:sequence>
							<xs:element name="data" type="xs:date">
								<xs:annotation>
									<xs:documentation>
										data zdarzenia gospodarczego
									</xs:documentation>
								</xs:annotation>
							</xs:element>
							<xs:element name="data_walut" type="xs:date" minOccurs="0">
								<xs:annotation>
									<xs:documentation>
										data zdarzenia gospodarczego dla wyznaczania kursów walut (brak oznacza, że jest taka sama jak w elemencie "paczka/dokument/data")
									</xs:documentation>
								</xs:annotation>
							</xs:element>
							<xs:sequence minOccurs="0">
								<xs:element name="waluta" type="waluta_t"/>
								<xs:element name="kurs" type="kurs_t">
									<xs:annotation>
										<xs:documentation>
											kurs waluty dla dnia zdarzenia gosp. tj. "paczka/dokument/data_walut" (notowanie z poprzedniego dnia roboczego)
										</xs:documentation>
									</xs:annotation>
								</xs:element>
							</xs:sequence>
							<xs:element name="data_wystawienia" type="xs:date" minOccurs="0">
								<xs:annotation>
									<xs:documentation>
										data wystawienia faktury
									</xs:documentation>
								</xs:annotation>
							</xs:element>
							<xs:element name="termin" type="xs:date" minOccurs="0">
								<xs:annotation>
									<xs:documentation>
										termin płatności faktury
									</xs:documentation>
								</xs:annotation>
							</xs:element>
							<xs:element name="numer" type="xs:string" minOccurs="0">
								<xs:annotation>
									<xs:documentation>
										numer dowodu księgowego
									</xs:documentation>
								</xs:annotation>
							</xs:element>
							<xs:element name="KSeF" minOccurs="0">
								<xs:annotation>
									<xs:documentation>
										numer (identyfikujący fakturę w) KSeF; typ taki sam jak w schemacie FA(2)
									</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:token">
										<xs:pattern value="([1-9]((\d[1-9])|([1-9]\d))\d{7}|M\d{9}|[A-Z]{3}\d{7})-(20[2-9][0-9]|2[1-9][0-9]{2}|[3-9][0-9]{3})(0[1-9]|1[0-2])(0[1-9]|[1-2][0-9]|3[0-1])-([0-9A-F]{6})-?([0-9A-F]{6})-([0-9A-F]{2})"/>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>

							<xs:element name="kontrahent" minOccurs="0">
								<xs:complexType>
									<xs:sequence>
										<xs:element name="NIP" minOccurs="0">
											<xs:annotation>
												<xs:documentation>
													Numer NIP lub kod kraju i numer VAT kontrahenta.
												</xs:documentation>
											</xs:annotation>
											<xs:simpleType>
												<xs:restriction base="xs:string">
													<xs:maxLength value="14"/>
												</xs:restriction>
											</xs:simpleType>
										</xs:element>
										<xs:element name="nazwa" type="xs:string" minOccurs="0"/>
										<xs:element name="adres" type="xs:string" minOccurs="0"/>
									</xs:sequence>
									<xs:attribute name="VAT" default="tak">
										<xs:simpleType>
											<xs:restriction base="xs:string">
												<xs:enumeration value="nie">
													<xs:annotation>
														<xs:documentation>
															Kontrahent nie jest czynnym podatnikiem VAT.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
												<xs:enumeration value="tak">
													<xs:annotation>
														<xs:documentation>
															Kontrahent jest czynnym podatnikiem VAT.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
											</xs:restriction>
										</xs:simpleType>
									</xs:attribute>
								</xs:complexType>
							</xs:element>

							<xs:element name="konto" type="xs:string" minOccurs="0">
								<xs:annotation>
									<xs:documentation>
										Numer konta analitycznego w Puzzlach.
									</xs:documentation>
								</xs:annotation>
							</xs:element>

							<xs:element name="opis" type="xs:string" minOccurs="0">
								<xs:annotation>
									<xs:documentation>
										Opis zdarzenia gospodarczego.
									</xs:documentation>
								</xs:annotation>
							</xs:element>

							<xs:element name="uwagi" type="xs:string" minOccurs="0"/>

							<xs:element name="ksieguj" minOccurs="0">
								<xs:annotation>
									<xs:documentation>
										Zapis do PKPiR lub ewidencji przychodów.
									</xs:documentation>
								</xs:annotation>
								<xs:complexType>
									<xs:sequence>
										<xs:element name="razem" type="money">
											<xs:annotation>
												<xs:documentation>
													Kwota dokumentu, której część (określona w elemencie "procent") lub całość ma być zaksięgowana.
												</xs:documentation>
											</xs:annotation>
										</xs:element>
										<xs:element name="procent" minOccurs="0">
											<xs:annotation>
												<xs:documentation>
													Ten element występuje w przypadku niektórych nabyć, gdy księgowana jest tylko część kwoty "razem".
													Wartość tego elementu określa jaka to część w procentach: "75" oznacza 75%, "20" oznacza 20%.
													Brak tego elementu oznacza, że księgowane jest 100%.
												</xs:documentation>
											</xs:annotation>
											<xs:simpleType>
												<xs:restriction base="xs:string">
													<xs:enumeration value="75"/>
													<xs:enumeration value="20"/>
												</xs:restriction>
											</xs:simpleType>
										</xs:element>
										<xs:element name="kasowo" type="flag" minOccurs="0">
											<xs:annotation>
												<xs:documentation>
													Obecność tego elementu oznacza, że do dokumentu stosuje się kasowy PIT.
												</xs:documentation>
											</xs:annotation>
										</xs:element>
										<xs:element name="np_zdrow" type="flag" minOccurs="0">
											<xs:annotation>
												<xs:documentation>
													Obecność tego elementu powoduje, że przychód albo koszt nie jest uwzględniany przy obliczaniu  podstawy wymiaru składki na ubezpieczenie zdrowotne.
													Ustawienie nie dotyczy kosztów badawczo-rozwojowych; one nigdy nie są uwzględniane.
												</xs:documentation>
											</xs:annotation>
										</xs:element>
										<xs:choice>
											<xs:element name="data" type="xs:date" minOccurs="0">
												<xs:annotation>
													<xs:documentation>
														Data wpisu do ewidencji przychodów. Nie występuje w przypadku zapisu do PKPiR.
													</xs:documentation>
												</xs:annotation>
											</xs:element>
											<xs:element name="opis_BR" type="xs:string" minOccurs="0">
												<xs:annotation>
													<xs:documentation>
														Opis kosztu działalności badawczo-rozwojowej. Występuje wyłącznie dla zapisów do PKPiR.
													</xs:documentation>
												</xs:annotation>
											</xs:element>
										</xs:choice>
									</xs:sequence>
									<xs:attribute name="ryczalt" default="3.0%">
										<xs:annotation>
											<xs:documentation>
												Stawka ryczałtu. Występuje tylko dla zapisów do ewidencji przychodów.
											</xs:documentation>
										</xs:annotation>
										<xs:simpleType>
											<xs:restriction base="xs:string">
												<xs:enumeration value="3.0%"/>
												<xs:enumeration value="5.5%"/>
												<xs:enumeration value="8.5%"/>
												<xs:enumeration value="10%"/>
												<xs:enumeration value="12%"/>
												<xs:enumeration value="14%"/>
												<xs:enumeration value="N"/><!--8,5% przychodów do 100000 zł oraz 12,5% przychodów od nadwyżki ponad 100000 zł-->
												<xs:enumeration value="2"/><!--15% od roku 2021, wcześniej - 17%-->
												<xs:enumeration value="1"/><!--17% od roku 2021, wcześniej - 20%-->
											</xs:restriction>
										</xs:simpleType>
									</xs:attribute>
								</xs:complexType>
							</xs:element>

							<xs:element name="rejVAT" minOccurs="0">
								<xs:annotation>
									<xs:documentation>
										Zapis do rejestru VAT.
									</xs:documentation>
								</xs:annotation>
								<xs:complexType>
									<xs:sequence>
										<xs:element name="data" type="xs:date" minOccurs="0">
											<xs:annotation>
												<xs:documentation>
													Data obowiązku albo odliczenia VAT.
												</xs:documentation>
											</xs:annotation>
										</xs:element>
										<xs:choice minOccurs="0">
											<xs:sequence minOccurs="0">
												<xs:annotation><xs:documentation>oznaczenia sprzedaży stosowane w JPK_V7M i JPK_V7K</xs:documentation></xs:annotation>
												<xs:element name="TypSprz" minOccurs="0">
													<xs:annotation><xs:documentation>oznaczenie dowodu sprzedaży</xs:documentation></xs:annotation>
													<xs:simpleType>
														<xs:list>
            									<xs:simpleType>
																<xs:restriction base="xs:string">
																	<xs:enumeration value="FP"/>
																	<xs:enumeration value="WEW"/>
																	<xs:enumeration value="RO"/>
																</xs:restriction>
															</xs:simpleType>
														</xs:list>
													</xs:simpleType>
												</xs:element>
												<xs:element name="ProcSprz" minOccurs="0">
													<xs:annotation><xs:documentation>oznaczenia procedur sprzedaży</xs:documentation></xs:annotation>
													<xs:simpleType>
														<xs:list>
            									<xs:simpleType>
																<xs:restriction base="xs:string">
																	<xs:enumeration value="SW"/>
																	<xs:enumeration value="EE"/>
																	<xs:enumeration value="TP"/>
																	<xs:enumeration value="TT_WNT"/>
																	<xs:enumeration value="TT_D"/>
																	<xs:enumeration value="MR_T"/>
																	<xs:enumeration value="MR_UZ"/>
																	<xs:enumeration value="I_42"/>
																	<xs:enumeration value="I_63"/>
																	<xs:enumeration value="B_SPV"/>
																	<xs:enumeration value="B_SPV_DOSTAWA"/>
																	<xs:enumeration value="B_MPV_PROWIZJA"/>
																	<xs:enumeration value="MPP"/>
																	<xs:enumeration value="WSTO_EE"/>
																	<xs:enumeration value="IED"/>
																</xs:restriction>
															</xs:simpleType>
														</xs:list>
													</xs:simpleType>
												</xs:element>
												<xs:element name="GTU" minOccurs="0">
													<xs:annotation><xs:documentation>oznaczenia dostaw towarów i świadczenia usług</xs:documentation></xs:annotation>
													<xs:simpleType>
														<xs:list>
            									<xs:simpleType>
																<xs:restriction base="xs:string">
																	<xs:enumeration value="01"/>
																	<xs:enumeration value="02"/>
																	<xs:enumeration value="03"/>
																	<xs:enumeration value="04"/>
																	<xs:enumeration value="05"/>
																	<xs:enumeration value="06"/>
																	<xs:enumeration value="07"/>
																	<xs:enumeration value="08"/>
																	<xs:enumeration value="09"/>
																	<xs:enumeration value="10"/>
																	<xs:enumeration value="11"/>
																	<xs:enumeration value="12"/>
																	<xs:enumeration value="13"/>
																</xs:restriction>
															</xs:simpleType>
														</xs:list>
													</xs:simpleType>
												</xs:element>
												<xs:choice minOccurs="0">
													<xs:element name="SprzKor" type="xs:date" minOccurs="0">
														<xs:annotation><xs:documentation>data sprzedaży korygowanej wg art. 89a ust. 1 lub 4</xs:documentation></xs:annotation>
													</xs:element>
													<xs:element name="ZD" type="xs:gYearMonth" minOccurs="0">
														<xs:annotation>
															<xs:documentation>
																Ten element może wystąpić tylko w przypadku dostawy. Jest to miesiąc, w którym dany dokument ma być uwzględniony w załączniku VAT-ZD deklaracji VAT-7 lub VAT-7K.
																To, czy i w którym miesiącu dokument zostanie faktycznie uwzględniony w VAT-ZD, zależy od innych danych (np. terminu płatności) i niestosowania w firmie docelowej metody kasowej.
															</xs:documentation>
														</xs:annotation>
													</xs:element>
												</xs:choice>
											</xs:sequence>
											<xs:sequence minOccurs="0">
												<xs:annotation><xs:documentation>oznaczenia zakupów stosowane w JPK_V7M i JPK_V7K</xs:documentation></xs:annotation>
												<xs:element name="TypZak" minOccurs="0">
													<xs:annotation><xs:documentation>oznaczenie dowodu zakupu</xs:documentation></xs:annotation>
													<xs:simpleType>
														<xs:list>
            									<xs:simpleType>
																<xs:restriction base="xs:string">
																	<xs:enumeration value="MK"/>
																	<xs:enumeration value="WEW"/>
																	<xs:enumeration value="VAT_RR"/>
																</xs:restriction>
															</xs:simpleType>
														</xs:list>
													</xs:simpleType>
												</xs:element>
												<xs:element name="ProcZak" minOccurs="0">
													<xs:annotation><xs:documentation>oznaczenia procedur zakupu</xs:documentation></xs:annotation>
													<xs:simpleType>
														<xs:list>
            									<xs:simpleType>
																<xs:restriction base="xs:string">
																	<xs:enumeration value="MPP"/>
																	<xs:enumeration value="IMP"/>
																	<xs:enumeration value="MR_T"/>
																	<xs:enumeration value="MR_UZ"/>
																	<xs:enumeration value="TP"/>
																	<xs:enumeration value="TT_WNT"/>
																</xs:restriction>
															</xs:simpleType>
														</xs:list>
													</xs:simpleType>
												</xs:element>
												<xs:element name="pojazd" minOccurs="0">
													<xs:annotation>
														<xs:documentation>
															Ten element może wystąpić tylko w przypadku nabycia środka trwałego lub pozostałego nabycia, gdy przysługuje odliczenie VAT.
															Obecność tego elementu oznacza, że odliczenie dotyczy pojazdu firmowego.
														</xs:documentation>
													</xs:annotation>
													<xs:complexType>
														<xs:sequence>
															<xs:element name="nr" type="xs:string" minOccurs="0">
																<xs:annotation>
																	<xs:documentation>
																		Numer rejestracyjny pojazdu.
																	</xs:documentation>
																</xs:annotation>
															</xs:element>
															<xs:element name="odlicz" minOccurs="0" fixed="50">
																<xs:annotation>
																	<xs:documentation>
																		Procent podatku przysługujący do odliczenia (50% w przypadku pojazdu używanego do celów biznesowych i prywatnych).
																		Brak tego elementu oznacza że przysługuje pełne (100%) odliczenie.
																	</xs:documentation>
																</xs:annotation>
																<xs:complexType>
																	<xs:simpleContent>
																		<xs:extension base="xs:byte">
																		</xs:extension>
																	</xs:simpleContent>
																</xs:complexType>
															</xs:element>
														</xs:sequence>
													</xs:complexType>
												</xs:element>
											</xs:sequence>
										</xs:choice>
										<xs:element name="skala" type="xs:gYearMonth" minOccurs="0">
											<xs:annotation>
												<xs:documentation>
													Miesiąc, w którym obowiązywały wartości stawek VAT zastosowane w dokumencie (stawki inne niż aktualne stosuje się np. w fakturze korygującej - stawki jak w korygowanej fakturze).
													Przykładowo: jeśli wartością elementu "skala" jest "2010-12", to stawce oznaczonej "podst" odpowiada wartość 22%; jeśli zaś wartością elementu "skala" jest "2011-01", to stawce "podst" odpowiada wartość 23%.
													Jeśli element "skala" w dokumencie nie występuje, to za jego wartość przyjmuje się domyślnie miesiąc z daty dokumentu.
													Wartość liczbowa zastosowanych stawek jest w Puzzlach wykorzystywana do ułatwienia edycji dokumentów oraz do kontroli zgodności kwot netto i VAT.
												</xs:documentation>
											</xs:annotation>
										</xs:element>
										<xs:element name="suma" minOccurs="0" maxOccurs="8">
											<xs:annotation>
												<xs:documentation>
													Podsumowanie netto i VAT dla stawki podatku określonej wartością atrybutu "stawka".
													Dla jednego dokumentu nie powinno być dwóch elementów "suma" o jednakowej wartości atrybutu "stawka".
												</xs:documentation>
											</xs:annotation>
											<xs:complexType>
												<xs:sequence>
													<xs:element name="netto" type="money" minOccurs="0">
														<xs:annotation>
															<xs:documentation>
																Podstawa opodatkowania. Jeśli jest równa zero, to element "netto" jest zbędny.
															</xs:documentation>
														</xs:annotation>
													</xs:element>
													<xs:element name="VAT" type="money" minOccurs="0">
														<xs:annotation>
															<xs:documentation>
																Kwota podatku. Jeśli jest równa zero, to element "VAT" jest zbędny. Ten element w ogóle nie powinien wystąpić dla stawek: "NP", "zw", "0K", "0R", "0E" i "0F".
															</xs:documentation>
														</xs:annotation>
													</xs:element>
												</xs:sequence>
												<xs:attribute name="stawka" use="required">
													<xs:simpleType>
														<xs:restriction base="xs:string">
															<xs:enumeration value="zw">
																<xs:annotation>
																	<xs:documentation>
																		Zwolnione od podatku.
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="NP">
																<xs:annotation>
																	<xs:documentation>
																		Nie podlega.
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="0K">
																<xs:annotation>
																	<xs:documentation>
																		Stawka 0%, dostawa krajowa.
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="0R">
																<xs:annotation>
																	<xs:documentation>
																		Stawka 0%, dostawa krajowa, o której mowa w art.129 ustawy.
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="0E">
																<xs:annotation>
																	<xs:documentation>
																		Stawka 0%, dostawa eksportowa.
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="0F">
																<xs:annotation>
																	<xs:documentation>
																		Stawka 0%, wewnątrzwspólnotowa dostawa towarów.
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="TAXI">
																<xs:annotation>
																	<xs:documentation>
																		Ryczałt od usług taksówek osobowych - art.114 ust.1 ustawy.
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="RR">
																<xs:annotation>
																	<xs:documentation>
																		Ryczałt rolniczy.
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="super">
																<xs:annotation>
																	<xs:documentation>
																		Stawka superobniżona wg art.41 ust.2a ustawy (aktualnie 3% albo 5%).
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="obniz">
																<xs:annotation>
																	<xs:documentation>
																		Stawka obniżona wg art.41 ust.2 ustawy (aktualnie 7% albo 8%).
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="podst">
																<xs:annotation>
																	<xs:documentation>
																		Stawka podstawowa (aktualnie 22% albo 23%).
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
														</xs:restriction>
													</xs:simpleType>
												</xs:attribute>
												<xs:attribute name="ext">
													<xs:annotation>
														<xs:documentation>
															Ten atrybut może wystąpić tylko w przypadku dostawy, gdy atrybut "stawka" ma wartość "NP".
															Brak atrybutu "ext" dla stawki NP oznacza, że chodzi o dostawę niepodlegającą VAT, dającą prawo do odliczenia.
														</xs:documentation>
													</xs:annotation>
													<xs:simpleType>
														<xs:restriction base="xs:string">
															<xs:enumeration value="art100">
																<xs:annotation>
																	<xs:documentation>
																		Dostawa, o której mowa w art. 100 ust. 1 ustawy, niepodlegająca VAT, dająca prawo do odliczenia.
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
															<xs:enumeration value="BO">
																<xs:annotation>
																	<xs:documentation>
																		Dostawa niepodlegająca VAT, bez prawa do odliczenia.
																		(Zastępuje dawną stawkę "NPBO")
																	</xs:documentation>
																</xs:annotation>
															</xs:enumeration>
														</xs:restriction>
													</xs:simpleType>
												</xs:attribute>
											</xs:complexType>
										</xs:element>
									</xs:sequence>
									<xs:attribute name="odlicz">
										<xs:annotation>
											<xs:documentation>
												Ten atrybut występuje wyłącznie dla nabyć.
											</xs:documentation>
										</xs:annotation>
										<xs:simpleType>
											<xs:restriction base="xs:string">
												<xs:enumeration value="nie">
													<xs:annotation>
														<xs:documentation>
															Zapis nie upoważnia do odliczenia VAT.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
												<xs:enumeration value="paliwa">
													<xs:annotation>
														<xs:documentation>
															Zapis dotyczy nabycia paliw, nie upoważnia do odliczenia VAT.
															Tej wartości nie należy stosować dla zdarzeń gospodarczych od kwietnia 2014 r.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
												<xs:enumeration value="pojazdy">
													<xs:annotation>
														<xs:documentation>
															Zapis dotyczy nabycia pojazdów, nie upoważnia do odliczenia VAT.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
											</xs:restriction>
										</xs:simpleType>
									</xs:attribute>
									<xs:attribute name="do_ksiegi" type="xs:string" fixed="brutto">
										<xs:annotation>
											<xs:documentation>
												Do PKPiR lub ewidencji przychodów wpisać wartość nie tylko netto, ale także nieodliczonego VAT.
												Jeśli ten atrybut nie występuje, to wpisywana jest wartość tylko netto.
											</xs:documentation>
										</xs:annotation>
									</xs:attribute>
									<xs:attribute name="sprz" default="op">
										<xs:annotation>
											<xs:documentation>
												Ten atrybut występuje wyłącznie dla nabyć.
											</xs:documentation>
										</xs:annotation>
										<xs:simpleType>
											<xs:restriction base="xs:string">
												<xs:enumeration value="op">
													<xs:annotation>
														<xs:documentation>
															Nabycie jest związane z dostawą opodatkowaną.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
												<xs:enumeration value="zw">
													<xs:annotation>
														<xs:documentation>
															Nabycie jest związane z dostawą zwolnioną.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
												<xs:enumeration value="zw+op">
													<xs:annotation>
														<xs:documentation>
															Nabycie jest związane z dostawą zwolnioną oraz opodatkowaną.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
											</xs:restriction>
										</xs:simpleType>
									</xs:attribute>
									<xs:attribute name="nalezny">
										<xs:simpleType>
											<xs:restriction base="xs:string">
												<xs:enumeration value="WN">
													<xs:annotation>
														<xs:documentation>
															Podatek należny od wewnątrzwspólnotowego nabycia. Tylko dla nabyć.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
												<xs:enumeration value="IT">
													<xs:annotation>
														<xs:documentation>
															Podatek należny od importu towarów (art. 33a ustawy). Tylko dla nabyć.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
												<xs:enumeration value="IU">
													<xs:annotation>
														<xs:documentation>
															Podatek należny od importu usług. Tylko dla nabyć.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
												<xs:enumeration value="DPN">
													<xs:annotation>
														<xs:documentation>
															Nabycie lub dostawa, dla której podatnikiem jest nabywca.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
											</xs:restriction>
										</xs:simpleType>
									</xs:attribute>
									<xs:attribute name="art28b" type="xs:string" fixed="tak">
										<xs:annotation>
											<xs:documentation>
												Ten atrybut może wystąpić wyłącznie gdy atrybut "nalezny" ma wartość "IU"; oznacza, że chodzi o import usług wg art. 28b ustawy.
											</xs:documentation>
										</xs:annotation>
									</xs:attribute>
									<xs:attribute name="art17ust1pkt">
										<xs:annotation>
											<xs:documentation>
												Ten atrybut może wystąpić wyłącznie gdy atrybut "nalezny" ma wartość "DPN".
											</xs:documentation>
										</xs:annotation>
										<xs:simpleType>
											<xs:restriction base="xs:string">
												<xs:enumeration value="8">
													<xs:annotation>
														<xs:documentation>
															Dotyczy wyłącznie dostaw. Oznacza że chodzi o dostawę wg art. 17 ust. 1 pkt 8, a nie - pkt 7, który jest domyślny.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
												<xs:enumeration value="7lub8">
													<xs:annotation>
														<xs:documentation>
															Dotyczy wyłącznie nabyć. Oznacza że chodzi o nabycie wg art. 17 ust. 1 pkt 7 lub 8, a nie - pkt 5, który jest domyślny.
														</xs:documentation>
													</xs:annotation>
												</xs:enumeration>
											</xs:restriction>
										</xs:simpleType>
									</xs:attribute>
									<xs:attribute name="pozastrukt" type="xs:string" fixed="tak">
										<xs:annotation>
											<xs:documentation>
												Ten atrybut występuje wyłącznie dla nabyć towarów handlowych, i oznacza, że nabycie nie jest uwzględniane w podziale dostaw wg proporcji nabyć.
											</xs:documentation>
										</xs:annotation>
									</xs:attribute>
									<xs:attribute name="trojkat" type="xs:string" fixed="tak">
										<xs:annotation>
											<xs:documentation>
												Ten atrybut występuje wyłącznie dla wewnątrzwspólnotowych nabyć i dostaw towarów, i oznacza transakcję trójstronną.
											</xs:documentation>
										</xs:annotation>
									</xs:attribute>
									<xs:attribute name="marza" type="xs:string">
										<xs:annotation>
											<xs:documentation>
												Ten atrybut występuje wyłącznie dla dostaw według procedury VAT marża.
												Wartością tego atrybutu jest numer dokumentu nabycia.
											</xs:documentation>
										</xs:annotation>
									</xs:attribute>
								</xs:complexType>
							</xs:element>

							<xs:element name="zaplata" minOccurs="0" maxOccurs="unbounded">
								<xs:annotation>
									<xs:documentation>
										Uregulowanie należności lub zobowiązania w części lub w całości. Brak dla dokumentu jakiegokolwiek elementu "zaplata", nawet pustego, oznacza, że dokument jest uregulowany w całości i na czas.
									</xs:documentation>
								</xs:annotation>
								<xs:complexType>
									<xs:sequence minOccurs="0">
										<xs:element name="data" type="xs:date"/>
										<xs:element name="kwota">
											<xs:simpleType>
												<xs:restriction base="money">
													<xs:minExclusive value="0"/>
												</xs:restriction>
											</xs:simpleType>
										</xs:element>
										<xs:sequence minOccurs="0">
											<xs:element name="waluta" type="waluta_t"/>
											<xs:element name="kurs1" type="kurs_t" minOccurs="0">
												<xs:annotation>
													<xs:documentation>
														kurs waluty dla dnia zdarzenia gosp. tj. "paczka/dokument/data_walut" (notowanie z poprzedniego dnia roboczego)
													</xs:documentation>
												</xs:annotation>
											</xs:element>
											<xs:element name="kurs2" type="kurs_t">
												<xs:annotation>
													<xs:documentation>
														kurs waluty dla dnia platnosci tj. "paczka/dokument/zaplata/data" (notowanie z poprzedniego dnia roboczego)
													</xs:documentation>
												</xs:annotation>
											</xs:element>
										</xs:sequence>
										<xs:element name="forma" minOccurs="0">
											<xs:simpleType>
												<xs:restriction base="xs:string">
													<xs:enumeration value="przelew"/>
													<xs:enumeration value="gotówka"/>
													<xs:enumeration value="kompensata"/>
												</xs:restriction>
											</xs:simpleType>
										</xs:element>
									</xs:sequence>
								</xs:complexType>
							</xs:element>
					</xs:sequence>
					<xs:attribute name="dekret" default="sprz">
						<xs:annotation>
							<xs:documentation>
								Rodzaj zdarzenia gospodarczego:
							</xs:documentation>
						</xs:annotation>
						<xs:simpleType>
							<xs:restriction base="xs:string">
								<xs:enumeration value="sprz">
									<xs:annotation>
										<xs:documentation>
											sprzedaż towarów lub usług
										</xs:documentation>
									</xs:annotation>
								</xs:enumeration>
								<xs:enumeration value="utarg">
									<xs:annotation>
										<xs:documentation>
											utarg
										</xs:documentation>
									</xs:annotation>
								</xs:enumeration>
								<xs:enumeration value="przych">
									<xs:annotation>
										<xs:documentation>
											pozostałe przychody
										</xs:documentation>
									</xs:annotation>
								</xs:enumeration>
								<xs:enumeration value="zakup">
									<xs:annotation>
										<xs:documentation>
											zakup towarów handlowych
										</xs:documentation>
									</xs:annotation>
								</xs:enumeration>
								<xs:enumeration value="koszt">
									<xs:annotation>
										<xs:documentation>
											koszty uboczne zakupu
										</xs:documentation>
									</xs:annotation>
								</xs:enumeration>
								<xs:enumeration value="wynagr">
									<xs:annotation>
										<xs:documentation>
											wynagrodzenia
										</xs:documentation>
									</xs:annotation>
								</xs:enumeration>
								<xs:enumeration value="wydatek">
									<xs:annotation>
										<xs:documentation>
											pozostałe wydatki
										</xs:documentation>
									</xs:annotation>
								</xs:enumeration>
								<xs:enumeration value="st">
									<xs:annotation>
										<xs:documentation>
											nabycie środka trwałego
										</xs:documentation>
									</xs:annotation>
								</xs:enumeration>
								<xs:enumeration value="BR">
									<xs:annotation>
										<xs:documentation>
											koszt działalności badawczo-rozwojowej
										</xs:documentation>
									</xs:annotation>
								</xs:enumeration>
							</xs:restriction>
						</xs:simpleType>
					</xs:attribute>
				</xs:complexType>
			</xs:element>
		</xs:sequence>
		<xs:attribute name="wersja" type="xs:byte" fixed="18">
			<xs:annotation>
				<xs:documentation>
					Wersja schematu, z którą zgodny jest plik XML.
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="ksiega" type="nie_tak">
			<xs:annotation>
				<xs:documentation>
					Wartość "tak" oznacza zapisy PKPiR, "nie" - ewidencji przychodów.
					Ten atrybut służy wyłącznie do sprawdzenia czy dane są importowane do odpowiedniej firmy.
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="VAT" type="nie_tak">
			<xs:annotation>
				<xs:documentation>
					Czy firma, z której pochodzą zapisy, jest podatnikiem VAT?
					Ten atrybut służy wyłącznie do sprawdzenia czy dane są importowane do odpowiedniej firmy.
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="miesiac" type="xs:gYearMonth">
			<xs:annotation>
				<xs:documentation>
					Miesiąc zdarzeń gospodarczych, których dotyczą zapisy.
					Ten atrybut służy wyłącznie do sprawdzenia czy dane są importowane do odpowiedniego miesiąca.
				</xs:documentation>
			</xs:annotation>
		</xs:attribute>
		<xs:attribute name="KSeF" default="prod">
			<xs:annotation>
				<xs:documentation>
					Określenie środowiska KSeF, z którego pochodzą numery KSeF zapisane w importowanym pliku.
					Jeśli jest to inne środowisko niż ustawione w firmie, do której importujemy, to numery KSeF są pomijane przy imporcie.
				</xs:documentation>
			</xs:annotation>
			<xs:simpleType>
				<xs:restriction base="xs:string">
					<xs:enumeration value="demo"><xs:annotation><xs:documentation>środowisko przedprodukcyjne (demo)</xs:documentation></xs:annotation></xs:enumeration>
					<xs:enumeration value="prod"><xs:annotation><xs:documentation>środowisko produkcyjne</xs:documentation></xs:annotation></xs:enumeration>
				</xs:restriction>
			</xs:simpleType>
		</xs:attribute>
		
	</xs:complexType>
</xs:element>

</xs:schema>