siba_api 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.github/workflows/main.yml +18 -0
- data/.gitignore +18 -0
- data/.irbrc +5 -0
- data/.rspec +3 -0
- data/.rubocop.yml +14 -0
- data/CHANGELOG.md +0 -0
- data/CODE_OF_CONDUCT.md +84 -0
- data/Dockerfile +11 -0
- data/Gemfile +16 -0
- data/Gemfile.lock +107 -0
- data/LICENSE.txt +21 -0
- data/README.md +61 -0
- data/Rakefile +12 -0
- data/SEFRootCA.zip +0 -0
- data/bin/console +16 -0
- data/bin/setup +8 -0
- data/docker-compose.yml +7 -0
- data/lib/siba_api/api/config/property.rb +25 -0
- data/lib/siba_api/api/config/property_set.rb +119 -0
- data/lib/siba_api/api/config.rb +101 -0
- data/lib/siba_api/api.rb +145 -0
- data/lib/siba_api/api_exceptions.rb +14 -0
- data/lib/siba_api/client.rb +144 -0
- data/lib/siba_api/configuration.rb +48 -0
- data/lib/siba_api/constants.rb +62 -0
- data/lib/siba_api/http_status_codes.rb +13 -0
- data/lib/siba_api/version.rb +5 -0
- data/lib/siba_api.rb +88 -0
- data/lib/xml/bal.xsd +196 -0
- data/lib/xml/countries.xml +1052 -0
- data/siba_api.gemspec +40 -0
- metadata +106 -0
data/lib/xml/bal.xsd
ADDED
@@ -0,0 +1,196 @@
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
2
|
+
<xs:schema id="MovimentoBAL" targetNamespace="http://sef.pt/BAws" xmlns:mstns="http://sef.pt/BAws" xmlns="http://sef.pt/BAws" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" attributeFormDefault="qualified" elementFormDefault="qualified">
|
3
|
+
<xs:annotation>
|
4
|
+
<xs:appinfo source="urn:schemas-microsoft-com:xml-msdatasource">
|
5
|
+
<DataSource DefaultConnectionIndex="0" FunctionsComponentName="QueriesTableAdapter" Modifier="AutoLayout, AnsiClass, Class, Public" SchemaSerializationMode="IncludeSchema" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
|
6
|
+
<Connections>
|
7
|
+
</Connections>
|
8
|
+
<Tables>
|
9
|
+
</Tables>
|
10
|
+
<Sources>
|
11
|
+
</Sources>
|
12
|
+
</DataSource>
|
13
|
+
</xs:appinfo>
|
14
|
+
</xs:annotation>
|
15
|
+
<xs:element name="MovimentoBAL" msdata:IsDataSet="true" msdata:UseCurrentLocale="true">
|
16
|
+
<xs:complexType>
|
17
|
+
<xs:choice minOccurs="0" maxOccurs="unbounded">
|
18
|
+
<xs:element name="Unidade_Hoteleira">
|
19
|
+
<xs:complexType>
|
20
|
+
<xs:sequence>
|
21
|
+
<xs:element name="Codigo_Unidade_Hoteleira">
|
22
|
+
<xs:simpleType>
|
23
|
+
<xs:restriction base="xs:string">
|
24
|
+
<xs:maxLength value="9" />
|
25
|
+
</xs:restriction>
|
26
|
+
</xs:simpleType>
|
27
|
+
</xs:element>
|
28
|
+
<xs:element name="Estabelecimento">
|
29
|
+
<xs:simpleType>
|
30
|
+
<xs:restriction base="xs:string">
|
31
|
+
<xs:maxLength value="2" />
|
32
|
+
</xs:restriction>
|
33
|
+
</xs:simpleType>
|
34
|
+
</xs:element>
|
35
|
+
<xs:element name="Nome">
|
36
|
+
<xs:simpleType>
|
37
|
+
<xs:restriction base="xs:string">
|
38
|
+
<xs:maxLength value="40" />
|
39
|
+
</xs:restriction>
|
40
|
+
</xs:simpleType>
|
41
|
+
</xs:element>
|
42
|
+
<xs:element name="Abreviatura">
|
43
|
+
<xs:simpleType>
|
44
|
+
<xs:restriction base="xs:string">
|
45
|
+
<xs:maxLength value="15" />
|
46
|
+
</xs:restriction>
|
47
|
+
</xs:simpleType>
|
48
|
+
</xs:element>
|
49
|
+
<xs:element name="Morada">
|
50
|
+
<xs:simpleType>
|
51
|
+
<xs:restriction base="xs:string">
|
52
|
+
<xs:maxLength value="40" />
|
53
|
+
</xs:restriction>
|
54
|
+
</xs:simpleType>
|
55
|
+
</xs:element>
|
56
|
+
<xs:element name="Localidade">
|
57
|
+
<xs:simpleType>
|
58
|
+
<xs:restriction base="xs:string">
|
59
|
+
<xs:maxLength value="30" />
|
60
|
+
</xs:restriction>
|
61
|
+
</xs:simpleType>
|
62
|
+
</xs:element>
|
63
|
+
<xs:element name="Codigo_Postal">
|
64
|
+
<xs:simpleType>
|
65
|
+
<xs:restriction base="xs:string">
|
66
|
+
<xs:maxLength value="4" />
|
67
|
+
</xs:restriction>
|
68
|
+
</xs:simpleType>
|
69
|
+
</xs:element>
|
70
|
+
<xs:element name="Zona_Postal">
|
71
|
+
<xs:simpleType>
|
72
|
+
<xs:restriction base="xs:string">
|
73
|
+
<xs:maxLength value="3" />
|
74
|
+
</xs:restriction>
|
75
|
+
</xs:simpleType>
|
76
|
+
</xs:element>
|
77
|
+
<xs:element name="Telefone">
|
78
|
+
<xs:simpleType>
|
79
|
+
<xs:restriction base="xs:string">
|
80
|
+
<xs:maxLength value="10" />
|
81
|
+
</xs:restriction>
|
82
|
+
</xs:simpleType>
|
83
|
+
</xs:element>
|
84
|
+
<xs:element name="Fax">
|
85
|
+
<xs:simpleType>
|
86
|
+
<xs:restriction base="xs:string">
|
87
|
+
<xs:maxLength value="10" />
|
88
|
+
</xs:restriction>
|
89
|
+
</xs:simpleType>
|
90
|
+
</xs:element>
|
91
|
+
<xs:element name="Nome_Contacto">
|
92
|
+
<xs:simpleType>
|
93
|
+
<xs:restriction base="xs:string">
|
94
|
+
<xs:maxLength value="40" />
|
95
|
+
</xs:restriction>
|
96
|
+
</xs:simpleType>
|
97
|
+
</xs:element>
|
98
|
+
<xs:element name="Email_Contacto" minOccurs="0">
|
99
|
+
<xs:simpleType>
|
100
|
+
<xs:restriction base="xs:string">
|
101
|
+
<xs:maxLength value="140" />
|
102
|
+
</xs:restriction>
|
103
|
+
</xs:simpleType>
|
104
|
+
</xs:element>
|
105
|
+
</xs:sequence>
|
106
|
+
</xs:complexType>
|
107
|
+
</xs:element>
|
108
|
+
<xs:element name="Boletim_Alojamento">
|
109
|
+
<xs:complexType>
|
110
|
+
<xs:sequence>
|
111
|
+
<xs:element name="Apelido">
|
112
|
+
<xs:simpleType>
|
113
|
+
<xs:restriction base="xs:string">
|
114
|
+
<xs:maxLength value="40" />
|
115
|
+
</xs:restriction>
|
116
|
+
</xs:simpleType>
|
117
|
+
</xs:element>
|
118
|
+
<xs:element name="Nome" minOccurs="0">
|
119
|
+
<xs:simpleType>
|
120
|
+
<xs:restriction base="xs:string">
|
121
|
+
<xs:maxLength value="40" />
|
122
|
+
</xs:restriction>
|
123
|
+
</xs:simpleType>
|
124
|
+
</xs:element>
|
125
|
+
<xs:element name="Nacionalidade">
|
126
|
+
<xs:simpleType>
|
127
|
+
<xs:restriction base="xs:string">
|
128
|
+
<xs:maxLength value="3" />
|
129
|
+
</xs:restriction>
|
130
|
+
</xs:simpleType>
|
131
|
+
</xs:element>
|
132
|
+
<xs:element name="Data_Nascimento" type="xs:dateTime" />
|
133
|
+
<xs:element name="Local_Nascimento" minOccurs="0">
|
134
|
+
<xs:simpleType>
|
135
|
+
<xs:restriction base="xs:string">
|
136
|
+
<xs:maxLength value="30" />
|
137
|
+
</xs:restriction>
|
138
|
+
</xs:simpleType>
|
139
|
+
</xs:element>
|
140
|
+
<xs:element name="Documento_Identificacao">
|
141
|
+
<xs:simpleType>
|
142
|
+
<xs:restriction base="xs:string">
|
143
|
+
<xs:maxLength value="16" />
|
144
|
+
</xs:restriction>
|
145
|
+
</xs:simpleType>
|
146
|
+
</xs:element>
|
147
|
+
<xs:element name="Pais_Emissor_Documento">
|
148
|
+
<xs:simpleType>
|
149
|
+
<xs:restriction base="xs:string">
|
150
|
+
<xs:maxLength value="3" />
|
151
|
+
</xs:restriction>
|
152
|
+
</xs:simpleType>
|
153
|
+
</xs:element>
|
154
|
+
<xs:element name="Tipo_Documento">
|
155
|
+
<xs:simpleType>
|
156
|
+
<xs:restriction base="xs:string">
|
157
|
+
<xs:maxLength value="3" />
|
158
|
+
</xs:restriction>
|
159
|
+
</xs:simpleType>
|
160
|
+
</xs:element>
|
161
|
+
<xs:element name="Data_Entrada" type="xs:dateTime" />
|
162
|
+
<xs:element name="Data_Saida" type="xs:dateTime" minOccurs="0" />
|
163
|
+
<xs:element name="Pais_Residencia_Origem">
|
164
|
+
<xs:simpleType>
|
165
|
+
<xs:restriction base="xs:string">
|
166
|
+
<xs:maxLength value="3" />
|
167
|
+
</xs:restriction>
|
168
|
+
</xs:simpleType>
|
169
|
+
</xs:element>
|
170
|
+
<xs:element name="Local_Residencia_Origem">
|
171
|
+
<xs:simpleType>
|
172
|
+
<xs:restriction base="xs:string">
|
173
|
+
<xs:maxLength value="30" />
|
174
|
+
</xs:restriction>
|
175
|
+
</xs:simpleType>
|
176
|
+
</xs:element>
|
177
|
+
</xs:sequence>
|
178
|
+
</xs:complexType>
|
179
|
+
</xs:element>
|
180
|
+
<xs:element name="Envio">
|
181
|
+
<xs:complexType>
|
182
|
+
<xs:sequence>
|
183
|
+
<xs:element name="Numero_Ficheiro" type="xs:int" />
|
184
|
+
<xs:element name="Data_Movimento" type="xs:dateTime" />
|
185
|
+
</xs:sequence>
|
186
|
+
</xs:complexType>
|
187
|
+
</xs:element>
|
188
|
+
</xs:choice>
|
189
|
+
</xs:complexType>
|
190
|
+
<xs:unique name="Constraint1" msdata:PrimaryKey="true">
|
191
|
+
<xs:selector xpath=".//mstns:Unidade_Hoteleira" />
|
192
|
+
<xs:field xpath="mstns:Codigo_Unidade_Hoteleira" />
|
193
|
+
<xs:field xpath="mstns:Estabelecimento" />
|
194
|
+
</xs:unique>
|
195
|
+
</xs:element>
|
196
|
+
</xs:schema>
|