<?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XMLSpy v2008 sp1 (http://www.altova.com) by Dan (Burzynski) -->
<!--W3C Schema generated by XMLSpy v2008 sp1 (http://www.altova.com)-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
	<xs:element name="moo">
		<xs:complexType>
			<xs:sequence>
				<xs:element name="request">
					<xs:complexType>
						<xs:sequence>
							<xs:element name="version">
								<xs:annotation>
									<xs:documentation>The version of the XML. It's 0.7 in this case.</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:decimal">
										<xs:enumeration value="0.7"/>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="api_key">
								<xs:annotation>
									<xs:documentation>Your API key</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:pattern value="[0-9a-z]{8}-[0-9a-z]{4}-[0-9a-z]{8}-[0-9a-z]{8}-[0-9a-z]{4}"/>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="call">
								<xs:annotation>
									<xs:documentation>The type of call that you're doing. At the moment, the only supported call is 'build'</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:enumeration value="build"/>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
							<xs:element name="return_to" type="xs:anyURI" nillable="true" minOccurs="0">
								<xs:annotation>
									<xs:documentation>A full URL optionally supplied to return the user to a page</xs:documentation>
								</xs:annotation>
							</xs:element>
							<xs:element name="fail_to" type="xs:anyURI" nillable="true" minOccurs="0">
								<xs:annotation>
									<xs:documentation>You can specify a URL to throw the user two if there was something wrong with the XML that was sent. And error message will be appended to the query string of the URL.</xs:documentation>
								</xs:annotation>
							</xs:element>
						</xs:sequence>
					</xs:complexType>
				</xs:element>
				<xs:element name="payload">
					<xs:complexType>
						<xs:choice>
							<xs:element name="chooser">
								<xs:annotation>
									<xs:documentation>Select the chooser path if you want to populate a list of images that the user can choose from to make cards with</xs:documentation>
								</xs:annotation>
								<xs:complexType>
									<xs:sequence>
										<xs:element ref="product_type"/>
										<xs:element name="images" maxOccurs="200">
											<xs:complexType>
												<xs:sequence>
													<xs:element name="url" type="xs:anyURI"/>
												</xs:sequence>
											</xs:complexType>
										</xs:element>
									</xs:sequence>
								</xs:complexType>
							</xs:element>
							<xs:element name="products">
								<xs:complexType>
									<xs:sequence>
										<xs:element name="product">
											<xs:annotation>
												<xs:documentation>Currently we only support the single product orders per request.</xs:documentation>
											</xs:annotation>
											<xs:complexType>
												<xs:sequence>
													<xs:element ref="product_type"/>
													<xs:element name="designs">
														<xs:complexType>
															<xs:sequence>
																<xs:element name="design" maxOccurs="100">
																	<xs:annotation>
																		<xs:documentation>There is one design for every item that you wish to add into the system. You can add more than a product supports to allow the user to choose from them.</xs:documentation>
																	</xs:annotation>
																	<xs:complexType>
																		<xs:sequence>
																			<xs:element name="image" maxOccurs="3">
																				<xs:annotation>
																					<xs:documentation>Add images to the design. There are three different types that you can use. See the enclosed 'type' element.</xs:documentation>
																				</xs:annotation>
																				<xs:complexType>
																					<xs:sequence>
																						<xs:element name="url" type="xs:anyURI">
																							<xs:annotation>
																								<xs:documentation>Location of the image to be grabbed</xs:documentation>
																							</xs:annotation>
																						</xs:element>
																						<xs:element name="type">
																							<xs:annotation>
																								<xs:documentation>The image type can be: variable (the main image on the front), logo (your own logo) or icon (a little icon). Currenctly only variable is supported</xs:documentation>
																							</xs:annotation>
																							<xs:simpleType>
																								<xs:restriction base="xs:string">
																									<xs:enumeration value="variable"/>
																								</xs:restriction>
																							</xs:simpleType>
																						</xs:element>
																						<xs:element name="crop" minOccurs="0">
																							<xs:annotation>
																								<xs:documentation>Optional cropping data. There are two modes, auto and manual.</xs:documentation>
																							</xs:annotation>
																							<xs:complexType>
																								<xs:choice>
																									<xs:element name="auto" type="xs:boolean" fixed="true">
																										<xs:annotation>
																											<xs:documentation>With an auto crop, we'll pick the largest area for each image that has been submitted based on the product_type</xs:documentation>
																										</xs:annotation>
																									</xs:element>
																									<xs:element name="manual">
																										<xs:complexType>
																											<xs:sequence>
																												<xs:element name="x">
																													<xs:annotation>
																														<xs:documentation>x position (in pixels) of the top left hand cornder of the cropping box</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:integer">
																															<xs:minInclusive value="0"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="y">
																													<xs:annotation>
																														<xs:documentation>y position (in pixels) of the top left hand cornder of the cropping box</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:integer">
																															<xs:minInclusive value="0"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="width">
																													<xs:annotation>
																														<xs:documentation>The width (in pixels) of the cropping area</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:integer">
																															<xs:minInclusive value="1"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="height">
																													<xs:annotation>
																														<xs:documentation>The height (in pixels) of the cropping area</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:integer">
																															<xs:minInclusive value="1"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																											</xs:sequence>
																										</xs:complexType>
																									</xs:element>
																								</xs:choice>
																							</xs:complexType>
																						</xs:element>
																					</xs:sequence>
																				</xs:complexType>
																			</xs:element>
																			<xs:element name="text_collection" minOccurs="0">
																				<xs:annotation>
																					<xs:documentation>Text additions are unsupported in this version of the API, but they're on their way</xs:documentation>
																				</xs:annotation>
																				<xs:complexType>
																					<xs:choice>
																						<xs:element name="minicard">
																							<xs:complexType>
																								<xs:sequence>
																									<xs:element name="text_line" maxOccurs="6">
																										<xs:complexType>
																											<xs:sequence>
																												<xs:element name="id">
																													<xs:annotation>
																														<xs:documentation>Line number from 1 to 6</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:integer">
																															<xs:minInclusive value="1"/>
																															<xs:maxInclusive value="6"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="string">
																													<xs:annotation>
																														<xs:documentation>Text for the line</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:maxLength value="37"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="size" minOccurs="0" maxOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Font size (unsupported)</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:integer">
																															<xs:minInclusive value="8"/>
																															<xs:maxInclusive value="16"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="bold" type="xs:boolean" default="false" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Bold or not?</xs:documentation>
																													</xs:annotation>
																												</xs:element>
																												<xs:element name="italic" type="xs:boolean" default="false" minOccurs="0" maxOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Italic or not? (unsupported)</xs:documentation>
																													</xs:annotation>
																												</xs:element>
																												<xs:element name="align" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Text alignment: left, right, center. Default left if ommitted</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:enumeration value="center"/>
																															<xs:enumeration value="right"/>
																															<xs:enumeration value="left"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="font" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Font: modern, traditional, typewriter. Default is 'modern' if ommitted</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:enumeration value="typewriter"/>
																															<xs:enumeration value="traditional"/>
																															<xs:enumeration value="modern"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="colour" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>A hexidecimal colour string (e.g. #ff0000). Default is #000000 if ommitted</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:pattern value="#[a-fA-F0-9]{6}"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																											</xs:sequence>
																										</xs:complexType>
																									</xs:element>
																								</xs:sequence>
																							</xs:complexType>
																						</xs:element>
																						<xs:element name="notecard">
																							<xs:complexType>
																								<xs:sequence>
																									<xs:element name="text_line" maxOccurs="5">
																										<xs:complexType>
																											<xs:sequence>
																												<xs:element name="id">
																													<xs:annotation>
																														<xs:documentation>Line number from 1 to 4 or 'main' for the main body of text</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:enumeration value="4"/>
																															<xs:enumeration value="3"/>
																															<xs:enumeration value="2"/>
																															<xs:enumeration value="1"/>
																															<xs:enumeration value="main"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="string" type="xs:string">
																													<xs:annotation>
																														<xs:documentation>Text for the line</xs:documentation>
																													</xs:annotation>
																												</xs:element>
																												<xs:element name="size" minOccurs="0" maxOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Font size (unsupported)</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:integer">
																															<xs:minInclusive value="8"/>
																															<xs:maxInclusive value="16"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="bold" type="xs:boolean" default="false" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Bold or not?</xs:documentation>
																													</xs:annotation>
																												</xs:element>
																												<xs:element name="italic" type="xs:boolean" default="false" minOccurs="0" maxOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Italic or not? (unsupported)</xs:documentation>
																													</xs:annotation>
																												</xs:element>
																												<xs:element name="align" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Text alignment: left, right, center. Default left if ommitted. The align for ids 1-4 should always be 'left'</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:enumeration value="center"/>
																															<xs:enumeration value="right"/>
																															<xs:enumeration value="left"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="font" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Font: modern, traditional, typewriter. Default is 'modern' if ommitted</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:enumeration value="typewriter"/>
																															<xs:enumeration value="traditional"/>
																															<xs:enumeration value="modern"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="colour" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>A hexidecimal colour string (e.g. #ff0000). Default is #000000 if ommitted</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:pattern value="#[a-fA-F0-9]{6}"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																											</xs:sequence>
																										</xs:complexType>
																									</xs:element>
																								</xs:sequence>
																							</xs:complexType>
																						</xs:element>
																						<xs:element name="postcard">
																							<xs:complexType>
																								<xs:sequence>
																									<xs:element name="text_line" maxOccurs="2">
																										<xs:complexType>
																											<xs:sequence>
																												<xs:element name="id">
																													<xs:annotation>
																														<xs:documentation>Either 'main' or 'bottom'</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:enumeration value="main"/>
																															<xs:enumeration value="bottom"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="string" type="xs:string">
																													<xs:annotation>
																														<xs:documentation>Text for the line</xs:documentation>
																													</xs:annotation>
																												</xs:element>
																												<xs:element name="size" minOccurs="0" maxOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Font size (unsupported)</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:integer">
																															<xs:minInclusive value="8"/>
																															<xs:maxInclusive value="16"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="bold" type="xs:boolean" default="false" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Bold or not?</xs:documentation>
																													</xs:annotation>
																												</xs:element>
																												<xs:element name="italic" type="xs:boolean" default="false" minOccurs="0" maxOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Italic or not? (unsupported)</xs:documentation>
																													</xs:annotation>
																												</xs:element>
																												<xs:element name="align" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Text alignment: left, right, center. Default left if ommitted</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:enumeration value="center"/>
																															<xs:enumeration value="right"/>
																															<xs:enumeration value="left"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="font" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Font: modern, traditional, typewriter. Default is 'modern' if ommitted</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:enumeration value="typewriter"/>
																															<xs:enumeration value="traditional"/>
																															<xs:enumeration value="modern"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="colour" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>A hexidecimal colour string (e.g. #ff0000). Default is #000000 if ommitted</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:pattern value="#[a-fA-F0-9]{6}"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																											</xs:sequence>
																										</xs:complexType>
																									</xs:element>
																								</xs:sequence>
																							</xs:complexType>
																						</xs:element>
																						<xs:element name="greetingcard">
																							<xs:complexType>
																								<xs:sequence>
																									<xs:element name="main" minOccurs="0">
																										<xs:complexType>
																											<xs:sequence>
																												<xs:element name="string" type="xs:string">
																													<xs:annotation>
																														<xs:documentation>Text for the center of the card</xs:documentation>
																													</xs:annotation>
																												</xs:element>
																												<xs:element name="align" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Alignment of the text box: center or right. Default is center</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:enumeration value="center"/>
																															<xs:enumeration value="right"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="font" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>Font to use from the list: modern, traditional, tidy, sticky, chunky, stencil, swirly, rounded, gothic, script, messy, drawn. Default is 'drawn' if ommitted.</xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:enumeration value="modern"/>
																															<xs:enumeration value="traditional"/>
																															<xs:enumeration value="tidy"/>
																															<xs:enumeration value="sticky"/>
																															<xs:enumeration value="chunky"/>
																															<xs:enumeration value="stencil"/>
																															<xs:enumeration value="swirly"/>
																															<xs:enumeration value="rounded"/>
																															<xs:enumeration value="gothic"/>
																															<xs:enumeration value="script"/>
																															<xs:enumeration value="messy"/>
																															<xs:enumeration value="drawn"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																												<xs:element name="colour" minOccurs="0">
																													<xs:annotation>
																														<xs:documentation>A hexidecimal colour string (e.g. #ff0000). Default is #000000 if ommitted </xs:documentation>
																													</xs:annotation>
																													<xs:simpleType>
																														<xs:restriction base="xs:string">
																															<xs:pattern value="#[a-fA-F0-9]{6}"/>
																														</xs:restriction>
																													</xs:simpleType>
																												</xs:element>
																											</xs:sequence>
																										</xs:complexType>
																									</xs:element>
																									<xs:element name="back" minOccurs="0">
																										<xs:complexType>
																											<xs:sequence>
																												<xs:element name="text_line" maxOccurs="4">
																													<xs:complexType>
																														<xs:sequence>
																															<xs:element name="id">
																																<xs:annotation>
																																	<xs:documentation>Line number from 1 to 4</xs:documentation>
																																</xs:annotation>
																																<xs:simpleType>
																																	<xs:restriction base="xs:string">
																																		<xs:enumeration value="4"/>
																																		<xs:enumeration value="3"/>
																																		<xs:enumeration value="2"/>
																																		<xs:enumeration value="1"/>
																																	</xs:restriction>
																																</xs:simpleType>
																															</xs:element>
																															<xs:element name="string" type="xs:string">
																																<xs:annotation>
																																	<xs:documentation>Text for the line</xs:documentation>
																																</xs:annotation>
																															</xs:element>
																															<xs:element name="size" minOccurs="0" maxOccurs="0">
																																<xs:annotation>
																																	<xs:documentation>Font size (unsupported)</xs:documentation>
																																</xs:annotation>
																																<xs:simpleType>
																																	<xs:restriction base="xs:integer">
																																		<xs:minInclusive value="8"/>
																																		<xs:maxInclusive value="16"/>
																																	</xs:restriction>
																																</xs:simpleType>
																															</xs:element>
																															<xs:element name="bold" type="xs:boolean" default="false" minOccurs="0">
																																<xs:annotation>
																																	<xs:documentation>Bold or not?</xs:documentation>
																																</xs:annotation>
																															</xs:element>
																															<xs:element name="italic" type="xs:boolean" default="false" minOccurs="0" maxOccurs="0">
																																<xs:annotation>
																																	<xs:documentation>Italic or not? (unsupported)</xs:documentation>
																																</xs:annotation>
																															</xs:element>
																															<xs:element name="align" minOccurs="0">
																																<xs:annotation>
																																	<xs:documentation>Text alignment: center. Default is center if ommitted</xs:documentation>
																																</xs:annotation>
																																<xs:simpleType>
																																	<xs:restriction base="xs:string">
																																		<xs:enumeration value="center"/>
																																	</xs:restriction>
																																</xs:simpleType>
																															</xs:element>
																															<xs:element name="font" minOccurs="0">
																																<xs:annotation>
																																	<xs:documentation>Font: modern, traditional, typewriter. Default is 'modern' if ommitted</xs:documentation>
																																</xs:annotation>
																																<xs:simpleType>
																																	<xs:restriction base="xs:string">
																																		<xs:enumeration value="typewriter"/>
																																		<xs:enumeration value="traditional"/>
																																		<xs:enumeration value="modern"/>
																																	</xs:restriction>
																																</xs:simpleType>
																															</xs:element>
																															<xs:element name="colour" minOccurs="0">
																																<xs:annotation>
																																	<xs:documentation>A hexidecimal colour string (e.g. #ff0000). Default is #000000 if ommitted</xs:documentation>
																																</xs:annotation>
																																<xs:simpleType>
																																	<xs:restriction base="xs:string">
																																		<xs:pattern value="#[a-fA-F0-9]{6}"/>
																																	</xs:restriction>
																																</xs:simpleType>
																															</xs:element>
																														</xs:sequence>
																													</xs:complexType>
																												</xs:element>
																											</xs:sequence>
																										</xs:complexType>
																									</xs:element>
																								</xs:sequence>
																							</xs:complexType>
																						</xs:element>
																					</xs:choice>
																				</xs:complexType>
																			</xs:element>
																		</xs:sequence>
																	</xs:complexType>
																</xs:element>
															</xs:sequence>
														</xs:complexType>
													</xs:element>
												</xs:sequence>
											</xs:complexType>
										</xs:element>
									</xs:sequence>
								</xs:complexType>
							</xs:element>
						</xs:choice>
					</xs:complexType>
				</xs:element>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
	<xs:element name="product_type">
		<xs:annotation>
			<xs:documentation>Select a print product type. Currently supported are: minicard, postcard, greetingcard, sticker and notecard</xs:documentation>
		</xs:annotation>
		<xs:simpleType>
			<xs:restriction base="xs:string">
				<xs:enumeration value="postcard"/>
				<xs:enumeration value="notecard"/>
				<xs:enumeration value="greetingcard"/>
				<xs:enumeration value="sticker"/>
				<xs:enumeration value="minicard"/>
			</xs:restriction>
		</xs:simpleType>
	</xs:element>
</xs:schema>
