printful_client 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/Gemfile +9 -0
- data/Gemfile.lock +72 -0
- data/LICENSE +21 -0
- data/README.md +43 -0
- data/docs/AddFile200Response.md +20 -0
- data/docs/Address.md +42 -0
- data/docs/AddressInfo.md +28 -0
- data/docs/ApprovalSheet.md +18 -0
- data/docs/ApprovalSheetChanges.md +20 -0
- data/docs/ApprovalSheetChangesFilesInner.md +18 -0
- data/docs/ApprovalSheetWebhookFile.md +24 -0
- data/docs/ApprovalSheetsAPIClient.md +216 -0
- data/docs/ApproveDesign200Response.md +20 -0
- data/docs/ApproveDesign200ResponseAllOfResult.md +18 -0
- data/docs/AvailabilityStatus.md +20 -0
- data/docs/AvailableTechnique.md +22 -0
- data/docs/AverageFulfillmentTime.md +20 -0
- data/docs/CalculateShippingRates.md +24 -0
- data/docs/CalculateShippingRates200Response.md +20 -0
- data/docs/CalculateTaxRates200Response.md +20 -0
- data/docs/CatalogAPIClient.md +400 -0
- data/docs/CatalogFileOption.md +24 -0
- data/docs/Category.md +26 -0
- data/docs/ChangePackingSlip200Response.md +20 -0
- data/docs/ChangePackingSlip200ResponseResult.md +18 -0
- data/docs/Costs.md +38 -0
- data/docs/CostsByAmountInner.md +34 -0
- data/docs/CostsByProductInner.md +26 -0
- data/docs/CostsByVariantInner.md +28 -0
- data/docs/Country.md +24 -0
- data/docs/CountryStateCodeAPIClient.md +69 -0
- data/docs/CreateGenerationTask.md +32 -0
- data/docs/CreateGeneratorTask200Response.md +20 -0
- data/docs/CreateOrder200Response.md +20 -0
- data/docs/CreateSyncProduct200Response.md +20 -0
- data/docs/CreateSyncProduct400Response.md +22 -0
- data/docs/CreateSyncProduct400ResponseError.md +20 -0
- data/docs/CreateWebhookRequest.md +22 -0
- data/docs/DeleteProductTemplate200Response.md +20 -0
- data/docs/DeleteProductTemplate200ResponseAllOfResult.md +18 -0
- data/docs/DeleteSyncVariant200Response.md +20 -0
- data/docs/EcommercePlatformSyncAPIClient.md +459 -0
- data/docs/EstimateOrderCosts200Response.md +20 -0
- data/docs/EstimateOrderCosts200ResponseAllOfResult.md +20 -0
- data/docs/File.md +50 -0
- data/docs/FileLibraryAPIClient.md +220 -0
- data/docs/FileOption.md +20 -0
- data/docs/FileType.md +26 -0
- data/docs/GenerationTask.md +26 -0
- data/docs/GenerationTaskExtraMockup.md +24 -0
- data/docs/GenerationTaskFile.md +24 -0
- data/docs/GenerationTaskFilePosition.md +28 -0
- data/docs/GenerationTaskMockup.md +24 -0
- data/docs/GenerationTaskTemplateFile.md +22 -0
- data/docs/GetApprovalSheets200Response.md +20 -0
- data/docs/GetCategories200Response.md +20 -0
- data/docs/GetCategoryById200Response.md +20 -0
- data/docs/GetCountries200Response.md +20 -0
- data/docs/GetOrderByIdIdParameter.md +49 -0
- data/docs/GetOrders200Response.md +22 -0
- data/docs/GetPrintfiles200Response.md +20 -0
- data/docs/GetProductById200Response.md +20 -0
- data/docs/GetProductSizeGuideById200Response.md +20 -0
- data/docs/GetProductSizeGuideById404Response.md +22 -0
- data/docs/GetProductSizeGuideById404ResponseError.md +20 -0
- data/docs/GetProductTemplateById200Response.md +20 -0
- data/docs/GetProductTemplates200Response.md +22 -0
- data/docs/GetProducts200Response.md +20 -0
- data/docs/GetProducts401Response.md +22 -0
- data/docs/GetProducts401ResponseError.md +20 -0
- data/docs/GetScopes200Response.md +20 -0
- data/docs/GetScopes200ResponseAllOfResult.md +18 -0
- data/docs/GetScopes200ResponseAllOfResultScopesInner.md +20 -0
- data/docs/GetStatistics200Response.md +20 -0
- data/docs/GetStore200Response.md +20 -0
- data/docs/GetStoreSyncVariantById200Response.md +20 -0
- data/docs/GetStores200Response.md +22 -0
- data/docs/GetStores403Response.md +22 -0
- data/docs/GetStores403ResponseError.md +20 -0
- data/docs/GetSyncProductById200Response.md +20 -0
- data/docs/GetSyncProductByIdIdParameter.md +49 -0
- data/docs/GetSyncProducts200Response.md +22 -0
- data/docs/GetSyncVariantById200Response.md +20 -0
- data/docs/GetTaxCountries200Response.md +20 -0
- data/docs/GetTaxCountries200ResponseResultInner.md +24 -0
- data/docs/GetTaxCountries200ResponseResultInnerAllOfStatesInner.md +18 -0
- data/docs/GetTemplates200Response.md +20 -0
- data/docs/GetVariantById200Response.md +20 -0
- data/docs/GetWarehouseProduct200Response.md +20 -0
- data/docs/GetWarehouseProducts200Response.md +22 -0
- data/docs/GetWebhooks200Response.md +20 -0
- data/docs/Gift.md +20 -0
- data/docs/IncompleteItem.md +26 -0
- data/docs/Item.md +52 -0
- data/docs/ItemFilesInner.md +52 -0
- data/docs/ItemFilesInnerAllOfPosition.md +30 -0
- data/docs/ItemInfo.md +26 -0
- data/docs/ItemOption.md +20 -0
- data/docs/Material.md +20 -0
- data/docs/Measurement.md +22 -0
- data/docs/MeasurementValue.md +24 -0
- data/docs/MockupGeneratorAPIClient.md +313 -0
- data/docs/OAuthAPIClient.md +74 -0
- data/docs/Option.md +20 -0
- data/docs/OptionType.md +28 -0
- data/docs/Order.md +52 -0
- data/docs/OrderCosts.md +38 -0
- data/docs/OrderEstimateCosts.md +36 -0
- data/docs/OrderEstimateRetailCosts.md +30 -0
- data/docs/OrderEvent.md +52 -0
- data/docs/OrderShipmentItem.md +24 -0
- data/docs/OrdersAPIClient.md +535 -0
- data/docs/PackingSlip.md +28 -0
- data/docs/Paging.md +22 -0
- data/docs/PricingBreakdown.md +24 -0
- data/docs/Printfile.md +28 -0
- data/docs/PrintfileInfo.md +28 -0
- data/docs/PrintfulCosts.md +20 -0
- data/docs/Product.md +50 -0
- data/docs/Product1.md +20 -0
- data/docs/Product1SyncVariantsInner.md +46 -0
- data/docs/ProductInfo.md +20 -0
- data/docs/ProductSizeGuide.md +22 -0
- data/docs/ProductTemplate.md +26 -0
- data/docs/ProductTemplatesAPIClient.md +221 -0
- data/docs/ProductVariant.md +24 -0
- data/docs/ProductsAPIClient.md +679 -0
- data/docs/Profit.md +20 -0
- data/docs/README.md +410 -0
- data/docs/ReportsAPIClient.md +87 -0
- data/docs/Response200.md +18 -0
- data/docs/Response200Paginated.md +20 -0
- data/docs/RetailCosts.md +30 -0
- data/docs/SalesAndCostsInner.md +32 -0
- data/docs/SalesAndCostsSummaryInner.md +24 -0
- data/docs/Shipment.md +36 -0
- data/docs/ShippingInfo.md +32 -0
- data/docs/ShippingRateAPIClient.md +81 -0
- data/docs/SizeTable.md +28 -0
- data/docs/State.md +20 -0
- data/docs/Statistics.md +18 -0
- data/docs/Store.md +22 -0
- data/docs/StoreInformationAPIClient.md +218 -0
- data/docs/StoreStatistics.md +38 -0
- data/docs/SubmitApprovalSheetChanges200Response.md +20 -0
- data/docs/SyncProduct.md +32 -0
- data/docs/SyncProductDeleted.md +22 -0
- data/docs/SyncProductEvent.md +32 -0
- data/docs/SyncProductInfo.md +20 -0
- data/docs/SyncVariant.md +46 -0
- data/docs/SyncVariantInfo.md +20 -0
- data/docs/SyncVariantProduct.md +24 -0
- data/docs/TaxAddressInfo.md +24 -0
- data/docs/TaxInfo.md +22 -0
- data/docs/TaxRateAPIClient.md +134 -0
- data/docs/TaxRequest.md +18 -0
- data/docs/Template.md +42 -0
- data/docs/TemplateById.md +42 -0
- data/docs/TemplateByIdColorsInner.md +20 -0
- data/docs/TemplateByIdOptionDataInner.md +20 -0
- data/docs/TemplateByIdPlacementOptionDataInner.md +20 -0
- data/docs/TemplateByIdPlacementOptionDataInnerOptionsInner.md +20 -0
- data/docs/TemplateByIdPlacementsInner.md +24 -0
- data/docs/TemplatePlacementConflict.md +20 -0
- data/docs/TemplateVariantMapping.md +20 -0
- data/docs/TemplateVariantMappingItem.md +20 -0
- data/docs/Templates.md +18 -0
- data/docs/ThreadColors200Response.md +20 -0
- data/docs/ThreadColorsRequest.md +18 -0
- data/docs/TotalPaidOrders.md +20 -0
- data/docs/UpdateSyncProductRequest.md +20 -0
- data/docs/UpdateSyncProductRequestSyncVariantsInner.md +46 -0
- data/docs/UpdateSyncVariantRequest.md +46 -0
- data/docs/Variant.md +42 -0
- data/docs/VariantInfo.md +20 -0
- data/docs/VariantPrintfile.md +20 -0
- data/docs/WarehouseProduct.md +30 -0
- data/docs/WarehouseProductVariant.md +36 -0
- data/docs/WarehouseProductsAPIClient.md +159 -0
- data/docs/Webhook.md +24 -0
- data/docs/WebhookAPIClient.md +225 -0
- data/docs/WebhookInfo.md +22 -0
- data/generate.sh +53 -0
- data/lib/printful_client/api/approval_sheets_api_client.rb +238 -0
- data/lib/printful_client/api/catalog_api_client.rb +394 -0
- data/lib/printful_client/api/country_state_code_api_client.rb +79 -0
- data/lib/printful_client/api/ecommerce_platform_sync_api_client.rb +435 -0
- data/lib/printful_client/api/file_library_api_client.rb +227 -0
- data/lib/printful_client/api/mockup_generator_api_client.rb +318 -0
- data/lib/printful_client/api/o_auth_api_client.rb +79 -0
- data/lib/printful_client/api/orders_api_client.rb +514 -0
- data/lib/printful_client/api/product_templates_api_client.rb +211 -0
- data/lib/printful_client/api/products_api_client.rb +651 -0
- data/lib/printful_client/api/reports_api_client.rb +106 -0
- data/lib/printful_client/api/shipping_rate_api_client.rb +93 -0
- data/lib/printful_client/api/store_information_api_client.rb +209 -0
- data/lib/printful_client/api/tax_rate_api_client.rb +147 -0
- data/lib/printful_client/api/warehouse_products_api_client.rb +157 -0
- data/lib/printful_client/api/webhook_api_client.rb +213 -0
- data/lib/printful_client/api_client.rb +392 -0
- data/lib/printful_client/api_error.rb +58 -0
- data/lib/printful_client/configuration.rb +297 -0
- data/lib/printful_client/models/add_file200_response.rb +231 -0
- data/lib/printful_client/models/address.rb +336 -0
- data/lib/printful_client/models/address_info.rb +287 -0
- data/lib/printful_client/models/approval_sheet.rb +256 -0
- data/lib/printful_client/models/approval_sheet_changes.rb +242 -0
- data/lib/printful_client/models/approval_sheet_changes_files_inner.rb +222 -0
- data/lib/printful_client/models/approval_sheet_webhook_file.rb +241 -0
- data/lib/printful_client/models/approve_design200_response.rb +231 -0
- data/lib/printful_client/models/approve_design200_response_all_of_result.rb +214 -0
- data/lib/printful_client/models/availability_status.rb +225 -0
- data/lib/printful_client/models/available_technique.rb +235 -0
- data/lib/printful_client/models/average_fulfillment_time.rb +226 -0
- data/lib/printful_client/models/calculate_shipping_rates.rb +261 -0
- data/lib/printful_client/models/calculate_shipping_rates200_response.rb +226 -0
- data/lib/printful_client/models/calculate_tax_rates200_response.rb +224 -0
- data/lib/printful_client/models/catalog_file_option.rb +244 -0
- data/lib/printful_client/models/category.rb +290 -0
- data/lib/printful_client/models/change_packing_slip200_response.rb +224 -0
- data/lib/printful_client/models/change_packing_slip200_response_result.rb +215 -0
- data/lib/printful_client/models/costs.rb +316 -0
- data/lib/printful_client/models/costs_by_amount_inner.rb +295 -0
- data/lib/printful_client/models/costs_by_product_inner.rb +255 -0
- data/lib/printful_client/models/costs_by_variant_inner.rb +265 -0
- data/lib/printful_client/models/country.rb +246 -0
- data/lib/printful_client/models/create_generation_task.rb +329 -0
- data/lib/printful_client/models/create_generator_task200_response.rb +231 -0
- data/lib/printful_client/models/create_order200_response.rb +231 -0
- data/lib/printful_client/models/create_sync_product200_response.rb +231 -0
- data/lib/printful_client/models/create_sync_product400_response.rb +234 -0
- data/lib/printful_client/models/create_sync_product400_response_error.rb +223 -0
- data/lib/printful_client/models/create_webhook_request.rb +259 -0
- data/lib/printful_client/models/delete_product_template200_response.rb +231 -0
- data/lib/printful_client/models/delete_product_template200_response_all_of_result.rb +215 -0
- data/lib/printful_client/models/delete_sync_variant200_response.rb +234 -0
- data/lib/printful_client/models/estimate_order_costs200_response.rb +231 -0
- data/lib/printful_client/models/estimate_order_costs200_response_all_of_result.rb +223 -0
- data/lib/printful_client/models/file.rb +385 -0
- data/lib/printful_client/models/file_option.rb +240 -0
- data/lib/printful_client/models/file_type.rb +257 -0
- data/lib/printful_client/models/generation_task.rb +294 -0
- data/lib/printful_client/models/generation_task_extra_mockup.rb +246 -0
- data/lib/printful_client/models/generation_task_file.rb +247 -0
- data/lib/printful_client/models/generation_task_file_position.rb +268 -0
- data/lib/printful_client/models/generation_task_mockup.rb +250 -0
- data/lib/printful_client/models/generation_task_template_file.rb +238 -0
- data/lib/printful_client/models/get_approval_sheets200_response.rb +233 -0
- data/lib/printful_client/models/get_categories200_response.rb +233 -0
- data/lib/printful_client/models/get_category_by_id200_response.rb +231 -0
- data/lib/printful_client/models/get_countries200_response.rb +233 -0
- data/lib/printful_client/models/get_order_by_id_id_parameter.rb +105 -0
- data/lib/printful_client/models/get_orders200_response.rb +242 -0
- data/lib/printful_client/models/get_printfiles200_response.rb +231 -0
- data/lib/printful_client/models/get_product_by_id200_response.rb +231 -0
- data/lib/printful_client/models/get_product_size_guide_by_id200_response.rb +231 -0
- data/lib/printful_client/models/get_product_size_guide_by_id404_response.rb +234 -0
- data/lib/printful_client/models/get_product_size_guide_by_id404_response_error.rb +223 -0
- data/lib/printful_client/models/get_product_template_by_id200_response.rb +231 -0
- data/lib/printful_client/models/get_product_templates200_response.rb +240 -0
- data/lib/printful_client/models/get_products200_response.rb +233 -0
- data/lib/printful_client/models/get_products401_response.rb +234 -0
- data/lib/printful_client/models/get_products401_response_error.rb +223 -0
- data/lib/printful_client/models/get_scopes200_response.rb +231 -0
- data/lib/printful_client/models/get_scopes200_response_all_of_result.rb +216 -0
- data/lib/printful_client/models/get_scopes200_response_all_of_result_scopes_inner.rb +223 -0
- data/lib/printful_client/models/get_statistics200_response.rb +224 -0
- data/lib/printful_client/models/get_store200_response.rb +231 -0
- data/lib/printful_client/models/get_store_sync_variant_by_id200_response.rb +231 -0
- data/lib/printful_client/models/get_stores200_response.rb +242 -0
- data/lib/printful_client/models/get_stores403_response.rb +234 -0
- data/lib/printful_client/models/get_stores403_response_error.rb +223 -0
- data/lib/printful_client/models/get_sync_product_by_id200_response.rb +231 -0
- data/lib/printful_client/models/get_sync_product_by_id_id_parameter.rb +105 -0
- data/lib/printful_client/models/get_sync_products200_response.rb +243 -0
- data/lib/printful_client/models/get_sync_variant_by_id200_response.rb +224 -0
- data/lib/printful_client/models/get_tax_countries200_response.rb +226 -0
- data/lib/printful_client/models/get_tax_countries200_response_result_inner.rb +252 -0
- data/lib/printful_client/models/get_tax_countries200_response_result_inner_all_of_states_inner.rb +215 -0
- data/lib/printful_client/models/get_templates200_response.rb +231 -0
- data/lib/printful_client/models/get_variant_by_id200_response.rb +231 -0
- data/lib/printful_client/models/get_warehouse_product200_response.rb +231 -0
- data/lib/printful_client/models/get_warehouse_products200_response.rb +243 -0
- data/lib/printful_client/models/get_webhooks200_response.rb +231 -0
- data/lib/printful_client/models/gift.rb +264 -0
- data/lib/printful_client/models/incomplete_item.rb +256 -0
- data/lib/printful_client/models/item.rb +389 -0
- data/lib/printful_client/models/item_files_inner.rb +400 -0
- data/lib/printful_client/models/item_files_inner_all_of_position.rb +286 -0
- data/lib/printful_client/models/item_info.rb +263 -0
- data/lib/printful_client/models/item_option.rb +240 -0
- data/lib/printful_client/models/material.rb +225 -0
- data/lib/printful_client/models/measurement.rb +245 -0
- data/lib/printful_client/models/measurement_value.rb +253 -0
- data/lib/printful_client/models/option.rb +226 -0
- data/lib/printful_client/models/option_type.rb +269 -0
- data/lib/printful_client/models/order.rb +406 -0
- data/lib/printful_client/models/order_costs.rb +322 -0
- data/lib/printful_client/models/order_estimate_costs.rb +306 -0
- data/lib/printful_client/models/order_estimate_retail_costs.rb +282 -0
- data/lib/printful_client/models/order_event.rb +396 -0
- data/lib/printful_client/models/order_shipment_item.rb +292 -0
- data/lib/printful_client/models/packing_slip.rb +266 -0
- data/lib/printful_client/models/paging.rb +236 -0
- data/lib/printful_client/models/pricing_breakdown.rb +246 -0
- data/lib/printful_client/models/printfile.rb +300 -0
- data/lib/printful_client/models/printfile_info.rb +270 -0
- data/lib/printful_client/models/printful_costs.rb +226 -0
- data/lib/printful_client/models/product.rb +383 -0
- data/lib/printful_client/models/product1.rb +241 -0
- data/lib/printful_client/models/product1_sync_variants_inner.rb +379 -0
- data/lib/printful_client/models/product_info.rb +225 -0
- data/lib/printful_client/models/product_size_guide.rb +261 -0
- data/lib/printful_client/models/product_template.rb +262 -0
- data/lib/printful_client/models/product_variant.rb +246 -0
- data/lib/printful_client/models/profit.rb +226 -0
- data/lib/printful_client/models/response200.rb +215 -0
- data/lib/printful_client/models/response200_paginated.rb +231 -0
- data/lib/printful_client/models/retail_costs.rb +282 -0
- data/lib/printful_client/models/sales_and_costs_inner.rb +285 -0
- data/lib/printful_client/models/sales_and_costs_summary_inner.rb +245 -0
- data/lib/printful_client/models/shipment.rb +308 -0
- data/lib/printful_client/models/shipping_info.rb +286 -0
- data/lib/printful_client/models/size_table.rb +328 -0
- data/lib/printful_client/models/state.rb +225 -0
- data/lib/printful_client/models/statistics.rb +218 -0
- data/lib/printful_client/models/store.rb +236 -0
- data/lib/printful_client/models/store_statistics.rb +322 -0
- data/lib/printful_client/models/submit_approval_sheet_changes200_response.rb +231 -0
- data/lib/printful_client/models/sync_product.rb +312 -0
- data/lib/printful_client/models/sync_product_deleted.rb +257 -0
- data/lib/printful_client/models/sync_product_event.rb +293 -0
- data/lib/printful_client/models/sync_product_info.rb +226 -0
- data/lib/printful_client/models/sync_variant.rb +359 -0
- data/lib/printful_client/models/sync_variant_info.rb +223 -0
- data/lib/printful_client/models/sync_variant_product.rb +252 -0
- data/lib/printful_client/models/tax_address_info.rb +274 -0
- data/lib/printful_client/models/tax_info.rb +236 -0
- data/lib/printful_client/models/tax_request.rb +222 -0
- data/lib/printful_client/models/template.rb +372 -0
- data/lib/printful_client/models/template_by_id.rb +335 -0
- data/lib/printful_client/models/template_by_id_colors_inner.rb +223 -0
- data/lib/printful_client/models/template_by_id_option_data_inner.rb +225 -0
- data/lib/printful_client/models/template_by_id_placement_option_data_inner.rb +225 -0
- data/lib/printful_client/models/template_by_id_placement_option_data_inner_options_inner.rb +224 -0
- data/lib/printful_client/models/template_by_id_placements_inner.rb +241 -0
- data/lib/printful_client/models/template_placement_conflict.rb +228 -0
- data/lib/printful_client/models/template_variant_mapping.rb +228 -0
- data/lib/printful_client/models/template_variant_mapping_item.rb +226 -0
- data/lib/printful_client/models/templates.rb +217 -0
- data/lib/printful_client/models/thread_colors200_response.rb +233 -0
- data/lib/printful_client/models/thread_colors_request.rb +215 -0
- data/lib/printful_client/models/total_paid_orders.rb +226 -0
- data/lib/printful_client/models/update_sync_product_request.rb +226 -0
- data/lib/printful_client/models/update_sync_product_request_sync_variants_inner.rb +365 -0
- data/lib/printful_client/models/update_sync_variant_request.rb +365 -0
- data/lib/printful_client/models/variant.rb +341 -0
- data/lib/printful_client/models/variant_info.rb +223 -0
- data/lib/printful_client/models/variant_printfile.rb +224 -0
- data/lib/printful_client/models/warehouse_product.rb +312 -0
- data/lib/printful_client/models/warehouse_product_variant.rb +306 -0
- data/lib/printful_client/models/webhook.rb +245 -0
- data/lib/printful_client/models/webhook_info.rb +238 -0
- data/lib/printful_client/version.rb +15 -0
- data/lib/printful_client.rb +216 -0
- data/printful_client.gemspec +38 -0
- data/spec/api/approval_sheets_api_client_spec.rb +75 -0
- data/spec/api/catalog_api_client_spec.rb +107 -0
- data/spec/api/country_state_code_api_client_spec.rb +46 -0
- data/spec/api/ecommerce_platform_sync_api_client_spec.rb +117 -0
- data/spec/api/file_library_api_client_spec.rb +73 -0
- data/spec/api/mockup_generator_api_client_spec.rb +92 -0
- data/spec/api/o_auth_api_client_spec.rb +46 -0
- data/spec/api/orders_api_client_spec.rb +131 -0
- data/spec/api/product_templates_api_client_spec.rb +72 -0
- data/spec/api/products_api_client_spec.rb +155 -0
- data/spec/api/reports_api_client_spec.rb +51 -0
- data/spec/api/shipping_rate_api_client_spec.rb +48 -0
- data/spec/api/store_information_api_client_spec.rb +71 -0
- data/spec/api/tax_rate_api_client_spec.rb +58 -0
- data/spec/api/warehouse_products_api_client_spec.rb +63 -0
- data/spec/api/webhook_api_client_spec.rb +72 -0
- data/spec/api_client_spec.rb +228 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/add_file200_response_spec.rb +40 -0
- data/spec/models/address_info_spec.rb +64 -0
- data/spec/models/address_spec.rb +106 -0
- data/spec/models/approval_sheet_changes_files_inner_spec.rb +34 -0
- data/spec/models/approval_sheet_changes_spec.rb +40 -0
- data/spec/models/approval_sheet_spec.rb +38 -0
- data/spec/models/approval_sheet_webhook_file_spec.rb +52 -0
- data/spec/models/approve_design200_response_all_of_result_spec.rb +34 -0
- data/spec/models/approve_design200_response_spec.rb +40 -0
- data/spec/models/availability_status_spec.rb +40 -0
- data/spec/models/available_technique_spec.rb +46 -0
- data/spec/models/average_fulfillment_time_spec.rb +40 -0
- data/spec/models/calculate_shipping_rates200_response_spec.rb +40 -0
- data/spec/models/calculate_shipping_rates_spec.rb +52 -0
- data/spec/models/calculate_tax_rates200_response_spec.rb +40 -0
- data/spec/models/catalog_file_option_spec.rb +52 -0
- data/spec/models/category_spec.rb +62 -0
- data/spec/models/change_packing_slip200_response_result_spec.rb +34 -0
- data/spec/models/change_packing_slip200_response_spec.rb +40 -0
- data/spec/models/costs_by_amount_inner_spec.rb +82 -0
- data/spec/models/costs_by_product_inner_spec.rb +58 -0
- data/spec/models/costs_by_variant_inner_spec.rb +64 -0
- data/spec/models/costs_spec.rb +94 -0
- data/spec/models/country_spec.rb +52 -0
- data/spec/models/create_generation_task_spec.rb +80 -0
- data/spec/models/create_generator_task200_response_spec.rb +40 -0
- data/spec/models/create_order200_response_spec.rb +40 -0
- data/spec/models/create_sync_product200_response_spec.rb +40 -0
- data/spec/models/create_sync_product400_response_error_spec.rb +40 -0
- data/spec/models/create_sync_product400_response_spec.rb +46 -0
- data/spec/models/create_webhook_request_spec.rb +46 -0
- data/spec/models/delete_product_template200_response_all_of_result_spec.rb +34 -0
- data/spec/models/delete_product_template200_response_spec.rb +40 -0
- data/spec/models/delete_sync_variant200_response_spec.rb +40 -0
- data/spec/models/estimate_order_costs200_response_all_of_result_spec.rb +40 -0
- data/spec/models/estimate_order_costs200_response_spec.rb +40 -0
- data/spec/models/file_option_spec.rb +40 -0
- data/spec/models/file_spec.rb +130 -0
- data/spec/models/file_type_spec.rb +58 -0
- data/spec/models/generation_task_extra_mockup_spec.rb +52 -0
- data/spec/models/generation_task_file_position_spec.rb +64 -0
- data/spec/models/generation_task_file_spec.rb +52 -0
- data/spec/models/generation_task_mockup_spec.rb +52 -0
- data/spec/models/generation_task_spec.rb +62 -0
- data/spec/models/generation_task_template_file_spec.rb +46 -0
- data/spec/models/get_approval_sheets200_response_spec.rb +40 -0
- data/spec/models/get_categories200_response_spec.rb +40 -0
- data/spec/models/get_category_by_id200_response_spec.rb +40 -0
- data/spec/models/get_countries200_response_spec.rb +40 -0
- data/spec/models/get_order_by_id_id_parameter_spec.rb +31 -0
- data/spec/models/get_orders200_response_spec.rb +46 -0
- data/spec/models/get_printfiles200_response_spec.rb +40 -0
- data/spec/models/get_product_by_id200_response_spec.rb +40 -0
- data/spec/models/get_product_size_guide_by_id200_response_spec.rb +40 -0
- data/spec/models/get_product_size_guide_by_id404_response_error_spec.rb +40 -0
- data/spec/models/get_product_size_guide_by_id404_response_spec.rb +46 -0
- data/spec/models/get_product_template_by_id200_response_spec.rb +40 -0
- data/spec/models/get_product_templates200_response_spec.rb +46 -0
- data/spec/models/get_products200_response_spec.rb +40 -0
- data/spec/models/get_products401_response_error_spec.rb +40 -0
- data/spec/models/get_products401_response_spec.rb +46 -0
- data/spec/models/get_scopes200_response_all_of_result_scopes_inner_spec.rb +40 -0
- data/spec/models/get_scopes200_response_all_of_result_spec.rb +34 -0
- data/spec/models/get_scopes200_response_spec.rb +40 -0
- data/spec/models/get_statistics200_response_spec.rb +40 -0
- data/spec/models/get_store200_response_spec.rb +40 -0
- data/spec/models/get_store_sync_variant_by_id200_response_spec.rb +40 -0
- data/spec/models/get_stores200_response_spec.rb +46 -0
- data/spec/models/get_stores403_response_error_spec.rb +40 -0
- data/spec/models/get_stores403_response_spec.rb +46 -0
- data/spec/models/get_sync_product_by_id200_response_spec.rb +40 -0
- data/spec/models/get_sync_product_by_id_id_parameter_spec.rb +31 -0
- data/spec/models/get_sync_products200_response_spec.rb +46 -0
- data/spec/models/get_sync_variant_by_id200_response_spec.rb +40 -0
- data/spec/models/get_tax_countries200_response_result_inner_all_of_states_inner_spec.rb +34 -0
- data/spec/models/get_tax_countries200_response_result_inner_spec.rb +52 -0
- data/spec/models/get_tax_countries200_response_spec.rb +40 -0
- data/spec/models/get_templates200_response_spec.rb +40 -0
- data/spec/models/get_variant_by_id200_response_spec.rb +40 -0
- data/spec/models/get_warehouse_product200_response_spec.rb +40 -0
- data/spec/models/get_warehouse_products200_response_spec.rb +46 -0
- data/spec/models/get_webhooks200_response_spec.rb +40 -0
- data/spec/models/gift_spec.rb +40 -0
- data/spec/models/incomplete_item_spec.rb +58 -0
- data/spec/models/item_files_inner_all_of_position_spec.rb +70 -0
- data/spec/models/item_files_inner_spec.rb +136 -0
- data/spec/models/item_info_spec.rb +58 -0
- data/spec/models/item_option_spec.rb +40 -0
- data/spec/models/item_spec.rb +136 -0
- data/spec/models/material_spec.rb +40 -0
- data/spec/models/measurement_spec.rb +46 -0
- data/spec/models/measurement_value_spec.rb +52 -0
- data/spec/models/option_spec.rb +40 -0
- data/spec/models/option_type_spec.rb +64 -0
- data/spec/models/order_costs_spec.rb +94 -0
- data/spec/models/order_estimate_costs_spec.rb +88 -0
- data/spec/models/order_estimate_retail_costs_spec.rb +70 -0
- data/spec/models/order_event_spec.rb +136 -0
- data/spec/models/order_shipment_item_spec.rb +60 -0
- data/spec/models/order_spec.rb +136 -0
- data/spec/models/packing_slip_spec.rb +64 -0
- data/spec/models/paging_spec.rb +46 -0
- data/spec/models/pricing_breakdown_spec.rb +52 -0
- data/spec/models/printfile_info_spec.rb +64 -0
- data/spec/models/printfile_spec.rb +68 -0
- data/spec/models/printful_costs_spec.rb +40 -0
- data/spec/models/product1_spec.rb +40 -0
- data/spec/models/product1_sync_variants_inner_spec.rb +118 -0
- data/spec/models/product_info_spec.rb +40 -0
- data/spec/models/product_size_guide_spec.rb +46 -0
- data/spec/models/product_spec.rb +130 -0
- data/spec/models/product_template_spec.rb +58 -0
- data/spec/models/product_variant_spec.rb +52 -0
- data/spec/models/profit_spec.rb +40 -0
- data/spec/models/response200_paginated_spec.rb +40 -0
- data/spec/models/response200_spec.rb +34 -0
- data/spec/models/retail_costs_spec.rb +70 -0
- data/spec/models/sales_and_costs_inner_spec.rb +76 -0
- data/spec/models/sales_and_costs_summary_inner_spec.rb +52 -0
- data/spec/models/shipment_spec.rb +88 -0
- data/spec/models/shipping_info_spec.rb +76 -0
- data/spec/models/size_table_spec.rb +72 -0
- data/spec/models/state_spec.rb +40 -0
- data/spec/models/statistics_spec.rb +34 -0
- data/spec/models/store_spec.rb +46 -0
- data/spec/models/store_statistics_spec.rb +94 -0
- data/spec/models/submit_approval_sheet_changes200_response_spec.rb +40 -0
- data/spec/models/sync_product_deleted_spec.rb +46 -0
- data/spec/models/sync_product_event_spec.rb +76 -0
- data/spec/models/sync_product_info_spec.rb +40 -0
- data/spec/models/sync_product_spec.rb +76 -0
- data/spec/models/sync_variant_info_spec.rb +40 -0
- data/spec/models/sync_variant_product_spec.rb +52 -0
- data/spec/models/sync_variant_spec.rb +118 -0
- data/spec/models/tax_address_info_spec.rb +52 -0
- data/spec/models/tax_info_spec.rb +46 -0
- data/spec/models/tax_request_spec.rb +34 -0
- data/spec/models/template_by_id_colors_inner_spec.rb +40 -0
- data/spec/models/template_by_id_option_data_inner_spec.rb +40 -0
- data/spec/models/template_by_id_placement_option_data_inner_options_inner_spec.rb +40 -0
- data/spec/models/template_by_id_placement_option_data_inner_spec.rb +40 -0
- data/spec/models/template_by_id_placements_inner_spec.rb +52 -0
- data/spec/models/template_by_id_spec.rb +106 -0
- data/spec/models/template_placement_conflict_spec.rb +40 -0
- data/spec/models/template_spec.rb +110 -0
- data/spec/models/template_variant_mapping_item_spec.rb +40 -0
- data/spec/models/template_variant_mapping_spec.rb +40 -0
- data/spec/models/templates_spec.rb +34 -0
- data/spec/models/thread_colors200_response_spec.rb +40 -0
- data/spec/models/thread_colors_request_spec.rb +34 -0
- data/spec/models/total_paid_orders_spec.rb +40 -0
- data/spec/models/update_sync_product_request_spec.rb +40 -0
- data/spec/models/update_sync_product_request_sync_variants_inner_spec.rb +118 -0
- data/spec/models/update_sync_variant_request_spec.rb +118 -0
- data/spec/models/variant_info_spec.rb +40 -0
- data/spec/models/variant_printfile_spec.rb +40 -0
- data/spec/models/variant_spec.rb +106 -0
- data/spec/models/warehouse_product_spec.rb +74 -0
- data/spec/models/warehouse_product_variant_spec.rb +88 -0
- data/spec/models/webhook_info_spec.rb +46 -0
- data/spec/models/webhook_spec.rb +52 -0
- data/spec/spec_helper.rb +111 -0
- data/swagger.json +8318 -0
- metadata +812 -0
@@ -0,0 +1,679 @@
|
|
1
|
+
# Printful::ProductsAPIClient
|
2
|
+
|
3
|
+
All URIs are relative to *https://api.printful.com*
|
4
|
+
|
5
|
+
| Method | HTTP request | Description |
|
6
|
+
| ------ | ------------ | ----------- |
|
7
|
+
| [**create_sync_product**](ProductsAPIClient.md#create_sync_product) | **POST** /store/products | Create a new Sync Product |
|
8
|
+
| [**create_sync_variant**](ProductsAPIClient.md#create_sync_variant) | **POST** /store/products/{id}/variants | Create a new Sync Variant |
|
9
|
+
| [**delete_sync_product**](ProductsAPIClient.md#delete_sync_product) | **DELETE** /store/products/{id} | Delete a Sync Product |
|
10
|
+
| [**delete_sync_variant**](ProductsAPIClient.md#delete_sync_variant) | **DELETE** /store/variants/{id} | Delete a Sync Variant |
|
11
|
+
| [**get_sync_product_by_id**](ProductsAPIClient.md#get_sync_product_by_id) | **GET** /store/products/{id} | Get a Sync Product |
|
12
|
+
| [**get_sync_products**](ProductsAPIClient.md#get_sync_products) | **GET** /store/products | Get Sync Products |
|
13
|
+
| [**get_sync_variant_by_id**](ProductsAPIClient.md#get_sync_variant_by_id) | **GET** /store/variants/{id} | Get a Sync Variant |
|
14
|
+
| [**update_sync_product**](ProductsAPIClient.md#update_sync_product) | **PUT** /store/products/{id} | Modify a Sync Product |
|
15
|
+
| [**update_sync_variant**](ProductsAPIClient.md#update_sync_variant) | **PUT** /store/variants/{id} | Modify a Sync Variant |
|
16
|
+
|
17
|
+
|
18
|
+
## create_sync_product
|
19
|
+
|
20
|
+
> <CreateSyncProduct200Response> create_sync_product(product1, opts)
|
21
|
+
|
22
|
+
Create a new Sync Product
|
23
|
+
|
24
|
+
Creates a new Sync Product together with its Sync Variants ([See examples](#section/Products-API-examples/Create-a-new-Sync-Product)).
|
25
|
+
|
26
|
+
### Examples
|
27
|
+
|
28
|
+
```ruby
|
29
|
+
require 'time'
|
30
|
+
require 'printful_client'
|
31
|
+
# setup authorization
|
32
|
+
Printful.configure do |config|
|
33
|
+
# Configure OAuth2 access token for authorization: OAuth
|
34
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
35
|
+
end
|
36
|
+
|
37
|
+
api_instance = Printful::ProductsAPIClient.new
|
38
|
+
product1 = Printful::Product1.new({sync_product: Printful::SyncProduct.new({name: 'T-shirt'}), sync_variants: [Printful::Product1SyncVariantsInner.new({variant_id: 3001, files: [3.56]})]}) # Product1 | POST request body
|
39
|
+
opts = {
|
40
|
+
x_pf_store_id: 'x_pf_store_id_example' # String | Use this to specify which store you want to use (required only for account level token)
|
41
|
+
}
|
42
|
+
|
43
|
+
begin
|
44
|
+
# Create a new Sync Product
|
45
|
+
result = api_instance.create_sync_product(product1, opts)
|
46
|
+
p result
|
47
|
+
rescue Printful::ApiError => e
|
48
|
+
puts "Error when calling ProductsAPIClient->create_sync_product: #{e}"
|
49
|
+
end
|
50
|
+
```
|
51
|
+
|
52
|
+
#### Using the create_sync_product_with_http_info variant
|
53
|
+
|
54
|
+
This returns an Array which contains the response data, status code and headers.
|
55
|
+
|
56
|
+
> <Array(<CreateSyncProduct200Response>, Integer, Hash)> create_sync_product_with_http_info(product1, opts)
|
57
|
+
|
58
|
+
```ruby
|
59
|
+
begin
|
60
|
+
# Create a new Sync Product
|
61
|
+
data, status_code, headers = api_instance.create_sync_product_with_http_info(product1, opts)
|
62
|
+
p status_code # => 2xx
|
63
|
+
p headers # => { ... }
|
64
|
+
p data # => <CreateSyncProduct200Response>
|
65
|
+
rescue Printful::ApiError => e
|
66
|
+
puts "Error when calling ProductsAPIClient->create_sync_product_with_http_info: #{e}"
|
67
|
+
end
|
68
|
+
```
|
69
|
+
|
70
|
+
### Parameters
|
71
|
+
|
72
|
+
| Name | Type | Description | Notes |
|
73
|
+
| ---- | ---- | ----------- | ----- |
|
74
|
+
| **product1** | [**Product1**](Product1.md) | POST request body | |
|
75
|
+
| **x_pf_store_id** | **String** | Use this to specify which store you want to use (required only for account level token) | [optional] |
|
76
|
+
|
77
|
+
### Return type
|
78
|
+
|
79
|
+
[**CreateSyncProduct200Response**](CreateSyncProduct200Response.md)
|
80
|
+
|
81
|
+
### Authorization
|
82
|
+
|
83
|
+
[OAuth](../README.md#OAuth)
|
84
|
+
|
85
|
+
### HTTP request headers
|
86
|
+
|
87
|
+
- **Content-Type**: application/json
|
88
|
+
- **Accept**: application/json
|
89
|
+
|
90
|
+
|
91
|
+
## create_sync_variant
|
92
|
+
|
93
|
+
> <GetSyncVariantById200Response> create_sync_variant(id, product1_sync_variants_inner, opts)
|
94
|
+
|
95
|
+
Create a new Sync Variant
|
96
|
+
|
97
|
+
Creates a new Sync Variant for an existing Sync Product ([See examples](#section/Products-API-examples/Create-a-new-Sync-Variant)).
|
98
|
+
|
99
|
+
### Examples
|
100
|
+
|
101
|
+
```ruby
|
102
|
+
require 'time'
|
103
|
+
require 'printful_client'
|
104
|
+
# setup authorization
|
105
|
+
Printful.configure do |config|
|
106
|
+
# Configure OAuth2 access token for authorization: OAuth
|
107
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
108
|
+
end
|
109
|
+
|
110
|
+
api_instance = Printful::ProductsAPIClient.new
|
111
|
+
id = nil # GetSyncProductByIdIdParameter | Sync Product ID (integer) or External ID (if prefixed with @)
|
112
|
+
product1_sync_variants_inner = Printful::Product1SyncVariantsInner.new({variant_id: 3001, files: [3.56]}) # Product1SyncVariantsInner | POST request body
|
113
|
+
opts = {
|
114
|
+
x_pf_store_id: 'x_pf_store_id_example' # String | Use this to specify which store you want to use (required only for account level token)
|
115
|
+
}
|
116
|
+
|
117
|
+
begin
|
118
|
+
# Create a new Sync Variant
|
119
|
+
result = api_instance.create_sync_variant(id, product1_sync_variants_inner, opts)
|
120
|
+
p result
|
121
|
+
rescue Printful::ApiError => e
|
122
|
+
puts "Error when calling ProductsAPIClient->create_sync_variant: #{e}"
|
123
|
+
end
|
124
|
+
```
|
125
|
+
|
126
|
+
#### Using the create_sync_variant_with_http_info variant
|
127
|
+
|
128
|
+
This returns an Array which contains the response data, status code and headers.
|
129
|
+
|
130
|
+
> <Array(<GetSyncVariantById200Response>, Integer, Hash)> create_sync_variant_with_http_info(id, product1_sync_variants_inner, opts)
|
131
|
+
|
132
|
+
```ruby
|
133
|
+
begin
|
134
|
+
# Create a new Sync Variant
|
135
|
+
data, status_code, headers = api_instance.create_sync_variant_with_http_info(id, product1_sync_variants_inner, opts)
|
136
|
+
p status_code # => 2xx
|
137
|
+
p headers # => { ... }
|
138
|
+
p data # => <GetSyncVariantById200Response>
|
139
|
+
rescue Printful::ApiError => e
|
140
|
+
puts "Error when calling ProductsAPIClient->create_sync_variant_with_http_info: #{e}"
|
141
|
+
end
|
142
|
+
```
|
143
|
+
|
144
|
+
### Parameters
|
145
|
+
|
146
|
+
| Name | Type | Description | Notes |
|
147
|
+
| ---- | ---- | ----------- | ----- |
|
148
|
+
| **id** | [**GetSyncProductByIdIdParameter**](.md) | Sync Product ID (integer) or External ID (if prefixed with @) | |
|
149
|
+
| **product1_sync_variants_inner** | [**Product1SyncVariantsInner**](Product1SyncVariantsInner.md) | POST request body | |
|
150
|
+
| **x_pf_store_id** | **String** | Use this to specify which store you want to use (required only for account level token) | [optional] |
|
151
|
+
|
152
|
+
### Return type
|
153
|
+
|
154
|
+
[**GetSyncVariantById200Response**](GetSyncVariantById200Response.md)
|
155
|
+
|
156
|
+
### Authorization
|
157
|
+
|
158
|
+
[OAuth](../README.md#OAuth)
|
159
|
+
|
160
|
+
### HTTP request headers
|
161
|
+
|
162
|
+
- **Content-Type**: application/json
|
163
|
+
- **Accept**: application/json
|
164
|
+
|
165
|
+
|
166
|
+
## delete_sync_product
|
167
|
+
|
168
|
+
> <GetSyncProductById200Response> delete_sync_product(id, opts)
|
169
|
+
|
170
|
+
Delete a Sync Product
|
171
|
+
|
172
|
+
Deletes a Sync Product with all of its Sync Variants
|
173
|
+
|
174
|
+
### Examples
|
175
|
+
|
176
|
+
```ruby
|
177
|
+
require 'time'
|
178
|
+
require 'printful_client'
|
179
|
+
# setup authorization
|
180
|
+
Printful.configure do |config|
|
181
|
+
# Configure OAuth2 access token for authorization: OAuth
|
182
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
183
|
+
end
|
184
|
+
|
185
|
+
api_instance = Printful::ProductsAPIClient.new
|
186
|
+
id = nil # GetSyncProductByIdIdParameter | Sync Product ID (integer) or External ID (if prefixed with @)
|
187
|
+
opts = {
|
188
|
+
x_pf_store_id: 'x_pf_store_id_example' # String | Use this to specify which store you want to use (required only for account level token)
|
189
|
+
}
|
190
|
+
|
191
|
+
begin
|
192
|
+
# Delete a Sync Product
|
193
|
+
result = api_instance.delete_sync_product(id, opts)
|
194
|
+
p result
|
195
|
+
rescue Printful::ApiError => e
|
196
|
+
puts "Error when calling ProductsAPIClient->delete_sync_product: #{e}"
|
197
|
+
end
|
198
|
+
```
|
199
|
+
|
200
|
+
#### Using the delete_sync_product_with_http_info variant
|
201
|
+
|
202
|
+
This returns an Array which contains the response data, status code and headers.
|
203
|
+
|
204
|
+
> <Array(<GetSyncProductById200Response>, Integer, Hash)> delete_sync_product_with_http_info(id, opts)
|
205
|
+
|
206
|
+
```ruby
|
207
|
+
begin
|
208
|
+
# Delete a Sync Product
|
209
|
+
data, status_code, headers = api_instance.delete_sync_product_with_http_info(id, opts)
|
210
|
+
p status_code # => 2xx
|
211
|
+
p headers # => { ... }
|
212
|
+
p data # => <GetSyncProductById200Response>
|
213
|
+
rescue Printful::ApiError => e
|
214
|
+
puts "Error when calling ProductsAPIClient->delete_sync_product_with_http_info: #{e}"
|
215
|
+
end
|
216
|
+
```
|
217
|
+
|
218
|
+
### Parameters
|
219
|
+
|
220
|
+
| Name | Type | Description | Notes |
|
221
|
+
| ---- | ---- | ----------- | ----- |
|
222
|
+
| **id** | [**GetSyncProductByIdIdParameter**](.md) | Sync Product ID (integer) or External ID (if prefixed with @) | |
|
223
|
+
| **x_pf_store_id** | **String** | Use this to specify which store you want to use (required only for account level token) | [optional] |
|
224
|
+
|
225
|
+
### Return type
|
226
|
+
|
227
|
+
[**GetSyncProductById200Response**](GetSyncProductById200Response.md)
|
228
|
+
|
229
|
+
### Authorization
|
230
|
+
|
231
|
+
[OAuth](../README.md#OAuth)
|
232
|
+
|
233
|
+
### HTTP request headers
|
234
|
+
|
235
|
+
- **Content-Type**: Not defined
|
236
|
+
- **Accept**: application/json
|
237
|
+
|
238
|
+
|
239
|
+
## delete_sync_variant
|
240
|
+
|
241
|
+
> <DeleteSyncVariant200Response> delete_sync_variant(id, opts)
|
242
|
+
|
243
|
+
Delete a Sync Variant
|
244
|
+
|
245
|
+
Deletes a single Sync Variant.
|
246
|
+
|
247
|
+
### Examples
|
248
|
+
|
249
|
+
```ruby
|
250
|
+
require 'time'
|
251
|
+
require 'printful_client'
|
252
|
+
# setup authorization
|
253
|
+
Printful.configure do |config|
|
254
|
+
# Configure OAuth2 access token for authorization: OAuth
|
255
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
256
|
+
end
|
257
|
+
|
258
|
+
api_instance = Printful::ProductsAPIClient.new
|
259
|
+
id = nil # GetSyncProductByIdIdParameter | Sync Variant ID (integer) or External ID (if prefixed with @)
|
260
|
+
opts = {
|
261
|
+
x_pf_store_id: 'x_pf_store_id_example' # String | Use this to specify which store you want to use (required only for account level token)
|
262
|
+
}
|
263
|
+
|
264
|
+
begin
|
265
|
+
# Delete a Sync Variant
|
266
|
+
result = api_instance.delete_sync_variant(id, opts)
|
267
|
+
p result
|
268
|
+
rescue Printful::ApiError => e
|
269
|
+
puts "Error when calling ProductsAPIClient->delete_sync_variant: #{e}"
|
270
|
+
end
|
271
|
+
```
|
272
|
+
|
273
|
+
#### Using the delete_sync_variant_with_http_info variant
|
274
|
+
|
275
|
+
This returns an Array which contains the response data, status code and headers.
|
276
|
+
|
277
|
+
> <Array(<DeleteSyncVariant200Response>, Integer, Hash)> delete_sync_variant_with_http_info(id, opts)
|
278
|
+
|
279
|
+
```ruby
|
280
|
+
begin
|
281
|
+
# Delete a Sync Variant
|
282
|
+
data, status_code, headers = api_instance.delete_sync_variant_with_http_info(id, opts)
|
283
|
+
p status_code # => 2xx
|
284
|
+
p headers # => { ... }
|
285
|
+
p data # => <DeleteSyncVariant200Response>
|
286
|
+
rescue Printful::ApiError => e
|
287
|
+
puts "Error when calling ProductsAPIClient->delete_sync_variant_with_http_info: #{e}"
|
288
|
+
end
|
289
|
+
```
|
290
|
+
|
291
|
+
### Parameters
|
292
|
+
|
293
|
+
| Name | Type | Description | Notes |
|
294
|
+
| ---- | ---- | ----------- | ----- |
|
295
|
+
| **id** | [**GetSyncProductByIdIdParameter**](.md) | Sync Variant ID (integer) or External ID (if prefixed with @) | |
|
296
|
+
| **x_pf_store_id** | **String** | Use this to specify which store you want to use (required only for account level token) | [optional] |
|
297
|
+
|
298
|
+
### Return type
|
299
|
+
|
300
|
+
[**DeleteSyncVariant200Response**](DeleteSyncVariant200Response.md)
|
301
|
+
|
302
|
+
### Authorization
|
303
|
+
|
304
|
+
[OAuth](../README.md#OAuth)
|
305
|
+
|
306
|
+
### HTTP request headers
|
307
|
+
|
308
|
+
- **Content-Type**: Not defined
|
309
|
+
- **Accept**: application/json
|
310
|
+
|
311
|
+
|
312
|
+
## get_sync_product_by_id
|
313
|
+
|
314
|
+
> <GetSyncProductById200Response> get_sync_product_by_id(id, opts)
|
315
|
+
|
316
|
+
Get a Sync Product
|
317
|
+
|
318
|
+
Get information about a single Sync Product and its Sync Variants.
|
319
|
+
|
320
|
+
### Examples
|
321
|
+
|
322
|
+
```ruby
|
323
|
+
require 'time'
|
324
|
+
require 'printful_client'
|
325
|
+
# setup authorization
|
326
|
+
Printful.configure do |config|
|
327
|
+
# Configure OAuth2 access token for authorization: OAuth
|
328
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
329
|
+
end
|
330
|
+
|
331
|
+
api_instance = Printful::ProductsAPIClient.new
|
332
|
+
id = nil # GetSyncProductByIdIdParameter | Sync Product ID (integer) or External ID (if prefixed with @)
|
333
|
+
opts = {
|
334
|
+
x_pf_store_id: 'x_pf_store_id_example' # String | Use this to specify which store you want to use (required only for account level token)
|
335
|
+
}
|
336
|
+
|
337
|
+
begin
|
338
|
+
# Get a Sync Product
|
339
|
+
result = api_instance.get_sync_product_by_id(id, opts)
|
340
|
+
p result
|
341
|
+
rescue Printful::ApiError => e
|
342
|
+
puts "Error when calling ProductsAPIClient->get_sync_product_by_id: #{e}"
|
343
|
+
end
|
344
|
+
```
|
345
|
+
|
346
|
+
#### Using the get_sync_product_by_id_with_http_info variant
|
347
|
+
|
348
|
+
This returns an Array which contains the response data, status code and headers.
|
349
|
+
|
350
|
+
> <Array(<GetSyncProductById200Response>, Integer, Hash)> get_sync_product_by_id_with_http_info(id, opts)
|
351
|
+
|
352
|
+
```ruby
|
353
|
+
begin
|
354
|
+
# Get a Sync Product
|
355
|
+
data, status_code, headers = api_instance.get_sync_product_by_id_with_http_info(id, opts)
|
356
|
+
p status_code # => 2xx
|
357
|
+
p headers # => { ... }
|
358
|
+
p data # => <GetSyncProductById200Response>
|
359
|
+
rescue Printful::ApiError => e
|
360
|
+
puts "Error when calling ProductsAPIClient->get_sync_product_by_id_with_http_info: #{e}"
|
361
|
+
end
|
362
|
+
```
|
363
|
+
|
364
|
+
### Parameters
|
365
|
+
|
366
|
+
| Name | Type | Description | Notes |
|
367
|
+
| ---- | ---- | ----------- | ----- |
|
368
|
+
| **id** | [**GetSyncProductByIdIdParameter**](.md) | Sync Product ID (integer) or External ID (if prefixed with @) | |
|
369
|
+
| **x_pf_store_id** | **String** | Use this to specify which store you want to use (required only for account level token) | [optional] |
|
370
|
+
|
371
|
+
### Return type
|
372
|
+
|
373
|
+
[**GetSyncProductById200Response**](GetSyncProductById200Response.md)
|
374
|
+
|
375
|
+
### Authorization
|
376
|
+
|
377
|
+
[OAuth](../README.md#OAuth)
|
378
|
+
|
379
|
+
### HTTP request headers
|
380
|
+
|
381
|
+
- **Content-Type**: Not defined
|
382
|
+
- **Accept**: application/json
|
383
|
+
|
384
|
+
|
385
|
+
## get_sync_products
|
386
|
+
|
387
|
+
> <GetSyncProducts200Response> get_sync_products(opts)
|
388
|
+
|
389
|
+
Get Sync Products
|
390
|
+
|
391
|
+
Returns a list of Sync Product objects from your custom Printful store.
|
392
|
+
|
393
|
+
### Examples
|
394
|
+
|
395
|
+
```ruby
|
396
|
+
require 'time'
|
397
|
+
require 'printful_client'
|
398
|
+
# setup authorization
|
399
|
+
Printful.configure do |config|
|
400
|
+
# Configure OAuth2 access token for authorization: OAuth
|
401
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
402
|
+
end
|
403
|
+
|
404
|
+
api_instance = Printful::ProductsAPIClient.new
|
405
|
+
opts = {
|
406
|
+
x_pf_store_id: 'x_pf_store_id_example', # String | Use this to specify which store you want to use (required only for account level token)
|
407
|
+
category_id: 'category_id_example' # String | A comma-separated list of Category IDs of the Products that are to be returned
|
408
|
+
}
|
409
|
+
|
410
|
+
begin
|
411
|
+
# Get Sync Products
|
412
|
+
result = api_instance.get_sync_products(opts)
|
413
|
+
p result
|
414
|
+
rescue Printful::ApiError => e
|
415
|
+
puts "Error when calling ProductsAPIClient->get_sync_products: #{e}"
|
416
|
+
end
|
417
|
+
```
|
418
|
+
|
419
|
+
#### Using the get_sync_products_with_http_info variant
|
420
|
+
|
421
|
+
This returns an Array which contains the response data, status code and headers.
|
422
|
+
|
423
|
+
> <Array(<GetSyncProducts200Response>, Integer, Hash)> get_sync_products_with_http_info(opts)
|
424
|
+
|
425
|
+
```ruby
|
426
|
+
begin
|
427
|
+
# Get Sync Products
|
428
|
+
data, status_code, headers = api_instance.get_sync_products_with_http_info(opts)
|
429
|
+
p status_code # => 2xx
|
430
|
+
p headers # => { ... }
|
431
|
+
p data # => <GetSyncProducts200Response>
|
432
|
+
rescue Printful::ApiError => e
|
433
|
+
puts "Error when calling ProductsAPIClient->get_sync_products_with_http_info: #{e}"
|
434
|
+
end
|
435
|
+
```
|
436
|
+
|
437
|
+
### Parameters
|
438
|
+
|
439
|
+
| Name | Type | Description | Notes |
|
440
|
+
| ---- | ---- | ----------- | ----- |
|
441
|
+
| **x_pf_store_id** | **String** | Use this to specify which store you want to use (required only for account level token) | [optional] |
|
442
|
+
| **category_id** | **String** | A comma-separated list of Category IDs of the Products that are to be returned | [optional] |
|
443
|
+
|
444
|
+
### Return type
|
445
|
+
|
446
|
+
[**GetSyncProducts200Response**](GetSyncProducts200Response.md)
|
447
|
+
|
448
|
+
### Authorization
|
449
|
+
|
450
|
+
[OAuth](../README.md#OAuth)
|
451
|
+
|
452
|
+
### HTTP request headers
|
453
|
+
|
454
|
+
- **Content-Type**: Not defined
|
455
|
+
- **Accept**: application/json
|
456
|
+
|
457
|
+
|
458
|
+
## get_sync_variant_by_id
|
459
|
+
|
460
|
+
> <GetSyncVariantById200Response> get_sync_variant_by_id(id, opts)
|
461
|
+
|
462
|
+
Get a Sync Variant
|
463
|
+
|
464
|
+
Get information about a single Sync Variant.
|
465
|
+
|
466
|
+
### Examples
|
467
|
+
|
468
|
+
```ruby
|
469
|
+
require 'time'
|
470
|
+
require 'printful_client'
|
471
|
+
# setup authorization
|
472
|
+
Printful.configure do |config|
|
473
|
+
# Configure OAuth2 access token for authorization: OAuth
|
474
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
475
|
+
end
|
476
|
+
|
477
|
+
api_instance = Printful::ProductsAPIClient.new
|
478
|
+
id = nil # GetSyncProductByIdIdParameter | Sync Variant ID (integer) or External ID (if prefixed with @)
|
479
|
+
opts = {
|
480
|
+
x_pf_store_id: 'x_pf_store_id_example' # String | Use this to specify which store you want to use (required only for account level token)
|
481
|
+
}
|
482
|
+
|
483
|
+
begin
|
484
|
+
# Get a Sync Variant
|
485
|
+
result = api_instance.get_sync_variant_by_id(id, opts)
|
486
|
+
p result
|
487
|
+
rescue Printful::ApiError => e
|
488
|
+
puts "Error when calling ProductsAPIClient->get_sync_variant_by_id: #{e}"
|
489
|
+
end
|
490
|
+
```
|
491
|
+
|
492
|
+
#### Using the get_sync_variant_by_id_with_http_info variant
|
493
|
+
|
494
|
+
This returns an Array which contains the response data, status code and headers.
|
495
|
+
|
496
|
+
> <Array(<GetSyncVariantById200Response>, Integer, Hash)> get_sync_variant_by_id_with_http_info(id, opts)
|
497
|
+
|
498
|
+
```ruby
|
499
|
+
begin
|
500
|
+
# Get a Sync Variant
|
501
|
+
data, status_code, headers = api_instance.get_sync_variant_by_id_with_http_info(id, opts)
|
502
|
+
p status_code # => 2xx
|
503
|
+
p headers # => { ... }
|
504
|
+
p data # => <GetSyncVariantById200Response>
|
505
|
+
rescue Printful::ApiError => e
|
506
|
+
puts "Error when calling ProductsAPIClient->get_sync_variant_by_id_with_http_info: #{e}"
|
507
|
+
end
|
508
|
+
```
|
509
|
+
|
510
|
+
### Parameters
|
511
|
+
|
512
|
+
| Name | Type | Description | Notes |
|
513
|
+
| ---- | ---- | ----------- | ----- |
|
514
|
+
| **id** | [**GetSyncProductByIdIdParameter**](.md) | Sync Variant ID (integer) or External ID (if prefixed with @) | |
|
515
|
+
| **x_pf_store_id** | **String** | Use this to specify which store you want to use (required only for account level token) | [optional] |
|
516
|
+
|
517
|
+
### Return type
|
518
|
+
|
519
|
+
[**GetSyncVariantById200Response**](GetSyncVariantById200Response.md)
|
520
|
+
|
521
|
+
### Authorization
|
522
|
+
|
523
|
+
[OAuth](../README.md#OAuth)
|
524
|
+
|
525
|
+
### HTTP request headers
|
526
|
+
|
527
|
+
- **Content-Type**: Not defined
|
528
|
+
- **Accept**: application/json
|
529
|
+
|
530
|
+
|
531
|
+
## update_sync_product
|
532
|
+
|
533
|
+
> <CreateSyncProduct200Response> update_sync_product(id, update_sync_product_request, opts)
|
534
|
+
|
535
|
+
Modify a Sync Product
|
536
|
+
|
537
|
+
Modifies an existing Sync Product with its Sync Variants. Please note that in the request body you only need to specify the fields that need to be changed. Furthermore, if you want to update existing sync variants, then in the sync variants array you must specify the IDs of all existing sync variants. All omitted existing sync variants will be deleted. All new sync variants without an ID will be created. See examples for more insights. **Rate limiting:** Up to 10 requests per 60 seconds. A 60 seconds lockout is applied if request count is exceeded. [See examples](#section/Products-API-examples/Modify-a-Sync-Product)
|
538
|
+
|
539
|
+
### Examples
|
540
|
+
|
541
|
+
```ruby
|
542
|
+
require 'time'
|
543
|
+
require 'printful_client'
|
544
|
+
# setup authorization
|
545
|
+
Printful.configure do |config|
|
546
|
+
# Configure OAuth2 access token for authorization: OAuth
|
547
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
548
|
+
end
|
549
|
+
|
550
|
+
api_instance = Printful::ProductsAPIClient.new
|
551
|
+
id = nil # GetSyncProductByIdIdParameter | Sync Product ID (integer) or External ID (if prefixed with @)
|
552
|
+
update_sync_product_request = Printful::UpdateSyncProductRequest.new # UpdateSyncProductRequest | PUT request body
|
553
|
+
opts = {
|
554
|
+
x_pf_store_id: 'x_pf_store_id_example' # String | Use this to specify which store you want to use (required only for account level token)
|
555
|
+
}
|
556
|
+
|
557
|
+
begin
|
558
|
+
# Modify a Sync Product
|
559
|
+
result = api_instance.update_sync_product(id, update_sync_product_request, opts)
|
560
|
+
p result
|
561
|
+
rescue Printful::ApiError => e
|
562
|
+
puts "Error when calling ProductsAPIClient->update_sync_product: #{e}"
|
563
|
+
end
|
564
|
+
```
|
565
|
+
|
566
|
+
#### Using the update_sync_product_with_http_info variant
|
567
|
+
|
568
|
+
This returns an Array which contains the response data, status code and headers.
|
569
|
+
|
570
|
+
> <Array(<CreateSyncProduct200Response>, Integer, Hash)> update_sync_product_with_http_info(id, update_sync_product_request, opts)
|
571
|
+
|
572
|
+
```ruby
|
573
|
+
begin
|
574
|
+
# Modify a Sync Product
|
575
|
+
data, status_code, headers = api_instance.update_sync_product_with_http_info(id, update_sync_product_request, opts)
|
576
|
+
p status_code # => 2xx
|
577
|
+
p headers # => { ... }
|
578
|
+
p data # => <CreateSyncProduct200Response>
|
579
|
+
rescue Printful::ApiError => e
|
580
|
+
puts "Error when calling ProductsAPIClient->update_sync_product_with_http_info: #{e}"
|
581
|
+
end
|
582
|
+
```
|
583
|
+
|
584
|
+
### Parameters
|
585
|
+
|
586
|
+
| Name | Type | Description | Notes |
|
587
|
+
| ---- | ---- | ----------- | ----- |
|
588
|
+
| **id** | [**GetSyncProductByIdIdParameter**](.md) | Sync Product ID (integer) or External ID (if prefixed with @) | |
|
589
|
+
| **update_sync_product_request** | [**UpdateSyncProductRequest**](UpdateSyncProductRequest.md) | PUT request body | |
|
590
|
+
| **x_pf_store_id** | **String** | Use this to specify which store you want to use (required only for account level token) | [optional] |
|
591
|
+
|
592
|
+
### Return type
|
593
|
+
|
594
|
+
[**CreateSyncProduct200Response**](CreateSyncProduct200Response.md)
|
595
|
+
|
596
|
+
### Authorization
|
597
|
+
|
598
|
+
[OAuth](../README.md#OAuth)
|
599
|
+
|
600
|
+
### HTTP request headers
|
601
|
+
|
602
|
+
- **Content-Type**: application/json
|
603
|
+
- **Accept**: application/json
|
604
|
+
|
605
|
+
|
606
|
+
## update_sync_variant
|
607
|
+
|
608
|
+
> <GetSyncVariantById200Response> update_sync_variant(id, update_sync_variant_request, opts)
|
609
|
+
|
610
|
+
Modify a Sync Variant
|
611
|
+
|
612
|
+
Modifies an existing Sync Variant. Please note that in the request body you only need to specify the fields that need to be changed. See examples for more insights. [See examples](#section/Products-API-examples/Modify-a-Sync-Variant)
|
613
|
+
|
614
|
+
### Examples
|
615
|
+
|
616
|
+
```ruby
|
617
|
+
require 'time'
|
618
|
+
require 'printful_client'
|
619
|
+
# setup authorization
|
620
|
+
Printful.configure do |config|
|
621
|
+
# Configure OAuth2 access token for authorization: OAuth
|
622
|
+
config.access_token = 'YOUR ACCESS TOKEN'
|
623
|
+
end
|
624
|
+
|
625
|
+
api_instance = Printful::ProductsAPIClient.new
|
626
|
+
id = nil # GetSyncProductByIdIdParameter | Sync Variant ID (integer) or External ID (if prefixed with @)
|
627
|
+
update_sync_variant_request = Printful::UpdateSyncVariantRequest.new # UpdateSyncVariantRequest | POST request body
|
628
|
+
opts = {
|
629
|
+
x_pf_store_id: 'x_pf_store_id_example' # String | Use this to specify which store you want to use (required only for account level token)
|
630
|
+
}
|
631
|
+
|
632
|
+
begin
|
633
|
+
# Modify a Sync Variant
|
634
|
+
result = api_instance.update_sync_variant(id, update_sync_variant_request, opts)
|
635
|
+
p result
|
636
|
+
rescue Printful::ApiError => e
|
637
|
+
puts "Error when calling ProductsAPIClient->update_sync_variant: #{e}"
|
638
|
+
end
|
639
|
+
```
|
640
|
+
|
641
|
+
#### Using the update_sync_variant_with_http_info variant
|
642
|
+
|
643
|
+
This returns an Array which contains the response data, status code and headers.
|
644
|
+
|
645
|
+
> <Array(<GetSyncVariantById200Response>, Integer, Hash)> update_sync_variant_with_http_info(id, update_sync_variant_request, opts)
|
646
|
+
|
647
|
+
```ruby
|
648
|
+
begin
|
649
|
+
# Modify a Sync Variant
|
650
|
+
data, status_code, headers = api_instance.update_sync_variant_with_http_info(id, update_sync_variant_request, opts)
|
651
|
+
p status_code # => 2xx
|
652
|
+
p headers # => { ... }
|
653
|
+
p data # => <GetSyncVariantById200Response>
|
654
|
+
rescue Printful::ApiError => e
|
655
|
+
puts "Error when calling ProductsAPIClient->update_sync_variant_with_http_info: #{e}"
|
656
|
+
end
|
657
|
+
```
|
658
|
+
|
659
|
+
### Parameters
|
660
|
+
|
661
|
+
| Name | Type | Description | Notes |
|
662
|
+
| ---- | ---- | ----------- | ----- |
|
663
|
+
| **id** | [**GetSyncProductByIdIdParameter**](.md) | Sync Variant ID (integer) or External ID (if prefixed with @) | |
|
664
|
+
| **update_sync_variant_request** | [**UpdateSyncVariantRequest**](UpdateSyncVariantRequest.md) | POST request body | |
|
665
|
+
| **x_pf_store_id** | **String** | Use this to specify which store you want to use (required only for account level token) | [optional] |
|
666
|
+
|
667
|
+
### Return type
|
668
|
+
|
669
|
+
[**GetSyncVariantById200Response**](GetSyncVariantById200Response.md)
|
670
|
+
|
671
|
+
### Authorization
|
672
|
+
|
673
|
+
[OAuth](../README.md#OAuth)
|
674
|
+
|
675
|
+
### HTTP request headers
|
676
|
+
|
677
|
+
- **Content-Type**: application/json
|
678
|
+
- **Accept**: application/json
|
679
|
+
|
data/docs/Profit.md
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
# Printful::Profit
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **value** | **Float** | The difference between Sales and Fulfillment. If retail price data is not available, profit might be negative | [optional] |
|
8
|
+
| **relative_difference** | **Float** | Relative difference from the value from the previous period. -1 means 100% decrease, 1 means 100% increase. 0 is returned if there is no change or the previous value was 0. | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'printful_client'
|
14
|
+
|
15
|
+
instance = Printful::Profit.new(
|
16
|
+
value: null,
|
17
|
+
relative_difference: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|