growwer 1.0.0
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/README.md +306 -0
- data/Rakefile +10 -0
- data/docs/AccountApi.md +213 -0
- data/docs/Balance.md +20 -0
- data/docs/BuyerMoneyApi.md +362 -0
- data/docs/CatalogueApi.md +731 -0
- data/docs/CatalogueMedia.md +46 -0
- data/docs/CatalogueMediaFlashOffer.md +20 -0
- data/docs/CatalogueMediaMetrics.md +26 -0
- data/docs/CatalogueOffer.md +24 -0
- data/docs/CatalogueOfferOrNull.md +24 -0
- data/docs/CataloguePostOffer.md +30 -0
- data/docs/CataloguePostOfferAllOfExtras.md +20 -0
- data/docs/CataloguePostOfferAllOfExtrasSensitiveTopic.md +20 -0
- data/docs/CodeName.md +20 -0
- data/docs/CountSavedFilterMedias200Response.md +18 -0
- data/docs/CreateProjectRequest.md +32 -0
- data/docs/CreateSavedFilterRequest.md +22 -0
- data/docs/Error.md +24 -0
- data/docs/FilesApi.md +79 -0
- data/docs/GetBuyerWallet200Response.md +20 -0
- data/docs/GetMe200Response.md +34 -0
- data/docs/GetMe200ResponseBuyer.md +18 -0
- data/docs/GetMe200ResponseCatalogue.md +18 -0
- data/docs/GetMe200ResponseManagedService.md +18 -0
- data/docs/GetMe200ResponseSeller.md +24 -0
- data/docs/GetSellerWallet200Response.md +20 -0
- data/docs/GetVocabulary200Response.md +28 -0
- data/docs/GetVocabulary200ResponseTopicsInner.md +20 -0
- data/docs/Invoice.md +24 -0
- data/docs/LinkAdditionOrderBriefing.md +22 -0
- data/docs/LinkAdditionOrderBriefingRequest.md +22 -0
- data/docs/ListBuyerTransactions200Response.md +20 -0
- data/docs/ListFlashOffers200Response.md +20 -0
- data/docs/ListInvoices200Response.md +20 -0
- data/docs/ListManagedServiceCampaigns200Response.md +20 -0
- data/docs/ListManagedServiceProposals200Response.md +20 -0
- data/docs/ListOrders200Response.md +20 -0
- data/docs/ListProjects200Response.md +20 -0
- data/docs/ListSavedFilters200Response.md +20 -0
- data/docs/ListSellerMedias200Response.md +20 -0
- data/docs/ListSellerOrders200Response.md +20 -0
- data/docs/ListSellerTransactions200Response.md +20 -0
- data/docs/ListWithdrawals200Response.md +20 -0
- data/docs/ManagedServiceCampaign.md +40 -0
- data/docs/ManagedServiceCampaignProject.md +20 -0
- data/docs/ManagedServiceCampaignProposalCounts.md +26 -0
- data/docs/ManagedServiceCampaignStrategy.md +26 -0
- data/docs/ManagedServiceProposal.md +40 -0
- data/docs/ManagedServiceProposalBriefing.md +24 -0
- data/docs/ManagedServiceProposalBriefingLinksInner.md +22 -0
- data/docs/ManagedServiceProposalMedia.md +24 -0
- data/docs/ManagedServiceProposalReview.md +20 -0
- data/docs/ManagedServiceProposalReviewRequest.md +18 -0
- data/docs/ManagedServiceProposalReviewRequestReviewsInner.md +22 -0
- data/docs/ManagedServiceProposalsEstimate.md +28 -0
- data/docs/ManagedServiceProposalsEstimateRequest.md +18 -0
- data/docs/ManagedServiceRequest.md +28 -0
- data/docs/ManagedServiceRequestSent.md +18 -0
- data/docs/ManagedServicesApi.md +593 -0
- data/docs/Money.md +20 -0
- data/docs/MoneyOrNull.md +20 -0
- data/docs/Order.md +48 -0
- data/docs/OrderActionReason.md +18 -0
- data/docs/OrderBriefing.md +49 -0
- data/docs/OrderChannel.md +18 -0
- data/docs/OrderCreateRequest.md +32 -0
- data/docs/OrderDelivery.md +20 -0
- data/docs/OrderDraft.md +22 -0
- data/docs/OrderEstimate.md +24 -0
- data/docs/OrderEstimateRequest.md +30 -0
- data/docs/OrderEstimateRequestBriefing.md +49 -0
- data/docs/OrderLink.md +22 -0
- data/docs/OrderLinkRequest.md +22 -0
- data/docs/OrderMedia.md +20 -0
- data/docs/OrderProject.md +20 -0
- data/docs/OrderStateHistoryInner.md +22 -0
- data/docs/OrderStateHistoryInnerReason.md +20 -0
- data/docs/OrdersApi.md +809 -0
- data/docs/PostOrderBriefing.md +28 -0
- data/docs/PostOrderBriefingRequest.md +24 -0
- data/docs/Project.md +38 -0
- data/docs/ProjectCatalogueMedia.md +48 -0
- data/docs/ProjectCatalogueMediaAllOfProject.md +28 -0
- data/docs/ProjectsApi.md +368 -0
- data/docs/PutSellerHoliday200Response.md +20 -0
- data/docs/PutSellerHolidayRequest.md +20 -0
- data/docs/RequestMedias201Response.md +18 -0
- data/docs/RequestMediasRequest.md +18 -0
- data/docs/SavedFilter.md +26 -0
- data/docs/SavedFilterNotifications.md +20 -0
- data/docs/SavedFiltersApi.md +296 -0
- data/docs/SellerFees.md +20 -0
- data/docs/SellerFeesOrNull.md +20 -0
- data/docs/SellerMedia.md +54 -0
- data/docs/SellerMediaFlashOffer.md +20 -0
- data/docs/SellerMediaLinkAdditionOffer.md +18 -0
- data/docs/SellerMediaLinkAdditionOfferPricingOptionsInner.md +22 -0
- data/docs/SellerMediaPostOffer.md +20 -0
- data/docs/SellerMediaPostOfferPricingOptionsInner.md +24 -0
- data/docs/SellerMediasApi.md +301 -0
- data/docs/SellerMoneyApi.md +364 -0
- data/docs/SellerOrder.md +50 -0
- data/docs/SellerOrderBriefing.md +49 -0
- data/docs/SellerOrderChannel.md +20 -0
- data/docs/SellerOrderDraft.md +20 -0
- data/docs/SellerOrderDraftFile.md +18 -0
- data/docs/SellerOrderPostDelivery.md +20 -0
- data/docs/SellerOrderProject.md +18 -0
- data/docs/SellerOrderRefutation.md +18 -0
- data/docs/SellerOrderRejection.md +18 -0
- data/docs/SellerOrderRejectionReason.md +20 -0
- data/docs/SellerOrdersApi.md +893 -0
- data/docs/SellerPostOrderBriefing.md +30 -0
- data/docs/SellerTransaction.md +38 -0
- data/docs/Transaction.md +40 -0
- data/docs/UpdateProjectRequest.md +30 -0
- data/docs/UpdateSellerMediaRequest.md +22 -0
- data/docs/UpdateSellerMediaRequestExtraServicesInner.md +20 -0
- data/docs/UpdateSellerMediaRequestLinkAdditionOffer.md +18 -0
- data/docs/UpdateSellerMediaRequestLinkAdditionOfferPricingOptionsInner.md +20 -0
- data/docs/UpdateSellerMediaRequestPostOffer.md +18 -0
- data/docs/UpdateSellerMediaRequestPostOfferPricingOptionsInner.md +22 -0
- data/docs/UploadFile201Response.md +24 -0
- data/docs/Withdrawal.md +28 -0
- data/git_push.sh +57 -0
- data/growwer.gemspec +41 -0
- data/lib/growwer/api/account_api.rb +215 -0
- data/lib/growwer/api/buyer_money_api.rb +355 -0
- data/lib/growwer/api/catalogue_api.rb +881 -0
- data/lib/growwer/api/files_api.rb +102 -0
- data/lib/growwer/api/managed_services_api.rb +625 -0
- data/lib/growwer/api/orders_api.rb +855 -0
- data/lib/growwer/api/projects_api.rb +398 -0
- data/lib/growwer/api/saved_filters_api.rb +319 -0
- data/lib/growwer/api/seller_medias_api.rb +329 -0
- data/lib/growwer/api/seller_money_api.rb +358 -0
- data/lib/growwer/api/seller_orders_api.rb +963 -0
- data/lib/growwer/api_client.rb +441 -0
- data/lib/growwer/api_error.rb +58 -0
- data/lib/growwer/api_model_base.rb +88 -0
- data/lib/growwer/configuration.rb +392 -0
- data/lib/growwer/models/balance.rb +192 -0
- data/lib/growwer/models/catalogue_media.rb +491 -0
- data/lib/growwer/models/catalogue_media_flash_offer.rb +191 -0
- data/lib/growwer/models/catalogue_media_metrics.rb +200 -0
- data/lib/growwer/models/catalogue_offer.rb +254 -0
- data/lib/growwer/models/catalogue_offer_or_null.rb +254 -0
- data/lib/growwer/models/catalogue_post_offer.rb +333 -0
- data/lib/growwer/models/catalogue_post_offer_all_of_extras.rb +177 -0
- data/lib/growwer/models/catalogue_post_offer_all_of_extras_sensitive_topic.rb +178 -0
- data/lib/growwer/models/code_name.rb +190 -0
- data/lib/growwer/models/count_saved_filter_medias200_response.rb +173 -0
- data/lib/growwer/models/create_project_request.rb +402 -0
- data/lib/growwer/models/create_saved_filter_request.rb +247 -0
- data/lib/growwer/models/error.rb +231 -0
- data/lib/growwer/models/get_buyer_wallet200_response.rb +191 -0
- data/lib/growwer/models/get_me200_response.rb +373 -0
- data/lib/growwer/models/get_me200_response_buyer.rb +164 -0
- data/lib/growwer/models/get_me200_response_catalogue.rb +165 -0
- data/lib/growwer/models/get_me200_response_managed_service.rb +165 -0
- data/lib/growwer/models/get_me200_response_seller.rb +231 -0
- data/lib/growwer/models/get_seller_wallet200_response.rb +191 -0
- data/lib/growwer/models/get_vocabulary200_response.rb +311 -0
- data/lib/growwer/models/get_vocabulary200_response_topics_inner.rb +190 -0
- data/lib/growwer/models/invoice.rb +243 -0
- data/lib/growwer/models/link_addition_order_briefing.rb +204 -0
- data/lib/growwer/models/link_addition_order_briefing_request.rb +201 -0
- data/lib/growwer/models/list_buyer_transactions200_response.rb +192 -0
- data/lib/growwer/models/list_flash_offers200_response.rb +192 -0
- data/lib/growwer/models/list_invoices200_response.rb +192 -0
- data/lib/growwer/models/list_managed_service_campaigns200_response.rb +192 -0
- data/lib/growwer/models/list_managed_service_proposals200_response.rb +192 -0
- data/lib/growwer/models/list_orders200_response.rb +192 -0
- data/lib/growwer/models/list_projects200_response.rb +192 -0
- data/lib/growwer/models/list_saved_filters200_response.rb +192 -0
- data/lib/growwer/models/list_seller_medias200_response.rb +192 -0
- data/lib/growwer/models/list_seller_orders200_response.rb +192 -0
- data/lib/growwer/models/list_seller_transactions200_response.rb +192 -0
- data/lib/growwer/models/list_withdrawals200_response.rb +192 -0
- data/lib/growwer/models/managed_service_campaign.rb +451 -0
- data/lib/growwer/models/managed_service_campaign_project.rb +190 -0
- data/lib/growwer/models/managed_service_campaign_proposal_counts.rb +269 -0
- data/lib/growwer/models/managed_service_campaign_strategy.rb +300 -0
- data/lib/growwer/models/managed_service_proposal.rb +428 -0
- data/lib/growwer/models/managed_service_proposal_briefing.rb +244 -0
- data/lib/growwer/models/managed_service_proposal_briefing_links_inner.rb +226 -0
- data/lib/growwer/models/managed_service_proposal_media.rb +214 -0
- data/lib/growwer/models/managed_service_proposal_review.rb +193 -0
- data/lib/growwer/models/managed_service_proposal_review_request.rb +176 -0
- data/lib/growwer/models/managed_service_proposal_review_request_reviews_inner.rb +240 -0
- data/lib/growwer/models/managed_service_proposals_estimate.rb +300 -0
- data/lib/growwer/models/managed_service_proposals_estimate_request.rb +150 -0
- data/lib/growwer/models/managed_service_request.rb +331 -0
- data/lib/growwer/models/managed_service_request_sent.rb +188 -0
- data/lib/growwer/models/money.rb +192 -0
- data/lib/growwer/models/money_or_null.rb +192 -0
- data/lib/growwer/models/order.rb +541 -0
- data/lib/growwer/models/order_action_reason.rb +183 -0
- data/lib/growwer/models/order_briefing.rb +102 -0
- data/lib/growwer/models/order_channel.rb +189 -0
- data/lib/growwer/models/order_create_request.rb +333 -0
- data/lib/growwer/models/order_delivery.rb +179 -0
- data/lib/growwer/models/order_draft.rb +220 -0
- data/lib/growwer/models/order_estimate.rb +246 -0
- data/lib/growwer/models/order_estimate_request.rb +299 -0
- data/lib/growwer/models/order_estimate_request_briefing.rb +102 -0
- data/lib/growwer/models/order_link.rb +214 -0
- data/lib/growwer/models/order_link_request.rb +209 -0
- data/lib/growwer/models/order_media.rb +178 -0
- data/lib/growwer/models/order_project.rb +178 -0
- data/lib/growwer/models/order_state_history_inner.rb +202 -0
- data/lib/growwer/models/order_state_history_inner_reason.rb +200 -0
- data/lib/growwer/models/post_order_briefing.rb +285 -0
- data/lib/growwer/models/post_order_briefing_request.rb +220 -0
- data/lib/growwer/models/project.rb +437 -0
- data/lib/growwer/models/project_catalogue_media.rb +524 -0
- data/lib/growwer/models/project_catalogue_media_all_of_project.rb +298 -0
- data/lib/growwer/models/put_seller_holiday200_response.rb +177 -0
- data/lib/growwer/models/put_seller_holiday_request.rb +174 -0
- data/lib/growwer/models/request_medias201_response.rb +166 -0
- data/lib/growwer/models/request_medias_request.rb +167 -0
- data/lib/growwer/models/saved_filter.rb +269 -0
- data/lib/growwer/models/saved_filter_notifications.rb +211 -0
- data/lib/growwer/models/seller_fees.rb +164 -0
- data/lib/growwer/models/seller_fees_or_null.rb +164 -0
- data/lib/growwer/models/seller_media.rb +573 -0
- data/lib/growwer/models/seller_media_flash_offer.rb +191 -0
- data/lib/growwer/models/seller_media_link_addition_offer.rb +167 -0
- data/lib/growwer/models/seller_media_link_addition_offer_pricing_options_inner.rb +228 -0
- data/lib/growwer/models/seller_media_post_offer.rb +195 -0
- data/lib/growwer/models/seller_media_post_offer_pricing_options_inner.rb +234 -0
- data/lib/growwer/models/seller_order.rb +563 -0
- data/lib/growwer/models/seller_order_briefing.rb +102 -0
- data/lib/growwer/models/seller_order_channel.rb +214 -0
- data/lib/growwer/models/seller_order_draft.rb +193 -0
- data/lib/growwer/models/seller_order_draft_file.rb +165 -0
- data/lib/growwer/models/seller_order_post_delivery.rb +193 -0
- data/lib/growwer/models/seller_order_project.rb +165 -0
- data/lib/growwer/models/seller_order_refutation.rb +183 -0
- data/lib/growwer/models/seller_order_rejection.rb +164 -0
- data/lib/growwer/models/seller_order_rejection_reason.rb +224 -0
- data/lib/growwer/models/seller_post_order_briefing.rb +314 -0
- data/lib/growwer/models/seller_transaction.rb +415 -0
- data/lib/growwer/models/transaction.rb +427 -0
- data/lib/growwer/models/update_project_request.rb +339 -0
- data/lib/growwer/models/update_seller_media_request.rb +168 -0
- data/lib/growwer/models/update_seller_media_request_extra_services_inner.rb +215 -0
- data/lib/growwer/models/update_seller_media_request_link_addition_offer.rb +166 -0
- data/lib/growwer/models/update_seller_media_request_link_addition_offer_pricing_options_inner.rb +215 -0
- data/lib/growwer/models/update_seller_media_request_post_offer.rb +175 -0
- data/lib/growwer/models/update_seller_media_request_post_offer_pricing_options_inner.rb +210 -0
- data/lib/growwer/models/upload_file201_response.rb +244 -0
- data/lib/growwer/models/withdrawal.rb +322 -0
- data/lib/growwer/version.rb +15 -0
- data/lib/growwer.rb +163 -0
- data/spec/api/account_api_spec.rb +70 -0
- data/spec/api/buyer_money_api_spec.rb +96 -0
- data/spec/api/catalogue_api_spec.rb +213 -0
- data/spec/api/files_api_spec.rb +48 -0
- data/spec/api/managed_services_api_spec.rb +140 -0
- data/spec/api/orders_api_spec.rb +182 -0
- data/spec/api/projects_api_spec.rb +100 -0
- data/spec/api/saved_filters_api_spec.rb +88 -0
- data/spec/api/seller_medias_api_spec.rb +89 -0
- data/spec/api/seller_money_api_spec.rb +97 -0
- data/spec/api/seller_orders_api_spec.rb +199 -0
- data/spec/models/balance_spec.rb +42 -0
- data/spec/models/catalogue_media_flash_offer_spec.rb +42 -0
- data/spec/models/catalogue_media_metrics_spec.rb +60 -0
- data/spec/models/catalogue_media_spec.rb +124 -0
- data/spec/models/catalogue_offer_or_null_spec.rb +58 -0
- data/spec/models/catalogue_offer_spec.rb +58 -0
- data/spec/models/catalogue_post_offer_all_of_extras_sensitive_topic_spec.rb +42 -0
- data/spec/models/catalogue_post_offer_all_of_extras_spec.rb +42 -0
- data/spec/models/catalogue_post_offer_spec.rb +80 -0
- data/spec/models/code_name_spec.rb +42 -0
- data/spec/models/count_saved_filter_medias200_response_spec.rb +36 -0
- data/spec/models/create_project_request_spec.rb +82 -0
- data/spec/models/create_saved_filter_request_spec.rb +52 -0
- data/spec/models/error_spec.rb +54 -0
- data/spec/models/get_buyer_wallet200_response_spec.rb +42 -0
- data/spec/models/get_me200_response_buyer_spec.rb +36 -0
- data/spec/models/get_me200_response_catalogue_spec.rb +36 -0
- data/spec/models/get_me200_response_managed_service_spec.rb +36 -0
- data/spec/models/get_me200_response_seller_spec.rb +54 -0
- data/spec/models/get_me200_response_spec.rb +84 -0
- data/spec/models/get_seller_wallet200_response_spec.rb +42 -0
- data/spec/models/get_vocabulary200_response_spec.rb +74 -0
- data/spec/models/get_vocabulary200_response_topics_inner_spec.rb +42 -0
- data/spec/models/invoice_spec.rb +54 -0
- data/spec/models/link_addition_order_briefing_request_spec.rb +48 -0
- data/spec/models/link_addition_order_briefing_spec.rb +48 -0
- data/spec/models/list_buyer_transactions200_response_spec.rb +42 -0
- data/spec/models/list_flash_offers200_response_spec.rb +42 -0
- data/spec/models/list_invoices200_response_spec.rb +42 -0
- data/spec/models/list_managed_service_campaigns200_response_spec.rb +42 -0
- data/spec/models/list_managed_service_proposals200_response_spec.rb +42 -0
- data/spec/models/list_orders200_response_spec.rb +42 -0
- data/spec/models/list_projects200_response_spec.rb +42 -0
- data/spec/models/list_saved_filters200_response_spec.rb +42 -0
- data/spec/models/list_seller_medias200_response_spec.rb +42 -0
- data/spec/models/list_seller_orders200_response_spec.rb +42 -0
- data/spec/models/list_seller_transactions200_response_spec.rb +42 -0
- data/spec/models/list_withdrawals200_response_spec.rb +42 -0
- data/spec/models/managed_service_campaign_project_spec.rb +42 -0
- data/spec/models/managed_service_campaign_proposal_counts_spec.rb +60 -0
- data/spec/models/managed_service_campaign_spec.rb +106 -0
- data/spec/models/managed_service_campaign_strategy_spec.rb +64 -0
- data/spec/models/managed_service_proposal_briefing_links_inner_spec.rb +52 -0
- data/spec/models/managed_service_proposal_briefing_spec.rb +54 -0
- data/spec/models/managed_service_proposal_media_spec.rb +54 -0
- data/spec/models/managed_service_proposal_review_request_reviews_inner_spec.rb +52 -0
- data/spec/models/managed_service_proposal_review_request_spec.rb +36 -0
- data/spec/models/managed_service_proposal_review_spec.rb +42 -0
- data/spec/models/managed_service_proposal_spec.rb +110 -0
- data/spec/models/managed_service_proposals_estimate_request_spec.rb +36 -0
- data/spec/models/managed_service_proposals_estimate_spec.rb +66 -0
- data/spec/models/managed_service_request_sent_spec.rb +40 -0
- data/spec/models/managed_service_request_spec.rb +74 -0
- data/spec/models/money_or_null_spec.rb +42 -0
- data/spec/models/money_spec.rb +42 -0
- data/spec/models/order_action_reason_spec.rb +36 -0
- data/spec/models/order_briefing_spec.rb +32 -0
- data/spec/models/order_channel_spec.rb +40 -0
- data/spec/models/order_create_request_spec.rb +82 -0
- data/spec/models/order_delivery_spec.rb +42 -0
- data/spec/models/order_draft_spec.rb +48 -0
- data/spec/models/order_estimate_request_briefing_spec.rb +32 -0
- data/spec/models/order_estimate_request_spec.rb +76 -0
- data/spec/models/order_estimate_spec.rb +54 -0
- data/spec/models/order_link_request_spec.rb +52 -0
- data/spec/models/order_link_spec.rb +52 -0
- data/spec/models/order_media_spec.rb +42 -0
- data/spec/models/order_project_spec.rb +42 -0
- data/spec/models/order_spec.rb +134 -0
- data/spec/models/order_state_history_inner_reason_spec.rb +46 -0
- data/spec/models/order_state_history_inner_spec.rb +48 -0
- data/spec/models/post_order_briefing_request_spec.rb +58 -0
- data/spec/models/post_order_briefing_spec.rb +70 -0
- data/spec/models/project_catalogue_media_all_of_project_spec.rb +66 -0
- data/spec/models/project_catalogue_media_spec.rb +130 -0
- data/spec/models/project_spec.rb +104 -0
- data/spec/models/put_seller_holiday200_response_spec.rb +42 -0
- data/spec/models/put_seller_holiday_request_spec.rb +42 -0
- data/spec/models/request_medias201_response_spec.rb +36 -0
- data/spec/models/request_medias_request_spec.rb +36 -0
- data/spec/models/saved_filter_notifications_spec.rb +46 -0
- data/spec/models/saved_filter_spec.rb +60 -0
- data/spec/models/seller_fees_or_null_spec.rb +42 -0
- data/spec/models/seller_fees_spec.rb +42 -0
- data/spec/models/seller_media_flash_offer_spec.rb +42 -0
- data/spec/models/seller_media_link_addition_offer_pricing_options_inner_spec.rb +52 -0
- data/spec/models/seller_media_link_addition_offer_spec.rb +36 -0
- data/spec/models/seller_media_post_offer_pricing_options_inner_spec.rb +58 -0
- data/spec/models/seller_media_post_offer_spec.rb +42 -0
- data/spec/models/seller_media_spec.rb +148 -0
- data/spec/models/seller_order_briefing_spec.rb +32 -0
- data/spec/models/seller_order_channel_spec.rb +50 -0
- data/spec/models/seller_order_draft_file_spec.rb +36 -0
- data/spec/models/seller_order_draft_spec.rb +42 -0
- data/spec/models/seller_order_post_delivery_spec.rb +42 -0
- data/spec/models/seller_order_project_spec.rb +36 -0
- data/spec/models/seller_order_refutation_spec.rb +36 -0
- data/spec/models/seller_order_rejection_reason_spec.rb +46 -0
- data/spec/models/seller_order_rejection_spec.rb +36 -0
- data/spec/models/seller_order_spec.rb +140 -0
- data/spec/models/seller_post_order_briefing_spec.rb +80 -0
- data/spec/models/seller_transaction_spec.rb +104 -0
- data/spec/models/transaction_spec.rb +110 -0
- data/spec/models/update_project_request_spec.rb +76 -0
- data/spec/models/update_seller_media_request_extra_services_inner_spec.rb +46 -0
- data/spec/models/update_seller_media_request_link_addition_offer_pricing_options_inner_spec.rb +46 -0
- data/spec/models/update_seller_media_request_link_addition_offer_spec.rb +36 -0
- data/spec/models/update_seller_media_request_post_offer_pricing_options_inner_spec.rb +52 -0
- data/spec/models/update_seller_media_request_post_offer_spec.rb +36 -0
- data/spec/models/update_seller_media_request_spec.rb +48 -0
- data/spec/models/upload_file201_response_spec.rb +54 -0
- data/spec/models/withdrawal_spec.rb +74 -0
- data/spec/spec_helper.rb +111 -0
- metadata +618 -0
data/docs/OrdersApi.md
ADDED
|
@@ -0,0 +1,809 @@
|
|
|
1
|
+
# Growwer::OrdersApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *https://tool.growwer.com*
|
|
4
|
+
|
|
5
|
+
| Method | HTTP request | Description |
|
|
6
|
+
| ------ | ------------ | ----------- |
|
|
7
|
+
| [**approve_order**](OrdersApi.md#approve_order) | **POST** /api/v1/orders/{id}/approve | Approve an order's delivery |
|
|
8
|
+
| [**approve_order_draft**](OrdersApi.md#approve_order_draft) | **POST** /api/v1/orders/{id}/approve-draft | Approve a draft |
|
|
9
|
+
| [**cancel_order**](OrdersApi.md#cancel_order) | **POST** /api/v1/orders/{id}/cancel | Cancel an order |
|
|
10
|
+
| [**create_order**](OrdersApi.md#create_order) | **POST** /api/v1/orders | Place an order |
|
|
11
|
+
| [**download_order_briefing**](OrdersApi.md#download_order_briefing) | **GET** /api/v1/orders/{id}/briefing | Download the draft you attached to an order |
|
|
12
|
+
| [**download_order_draft**](OrdersApi.md#download_order_draft) | **GET** /api/v1/orders/{id}/draft | Download the draft of an order |
|
|
13
|
+
| [**estimate_order**](OrdersApi.md#estimate_order) | **POST** /api/v1/orders/estimate | Estimate an order |
|
|
14
|
+
| [**get_order**](OrdersApi.md#get_order) | **GET** /api/v1/orders/{id} | Get an order |
|
|
15
|
+
| [**list_orders**](OrdersApi.md#list_orders) | **GET** /api/v1/orders | List your orders |
|
|
16
|
+
| [**request_order_draft_update**](OrdersApi.md#request_order_draft_update) | **POST** /api/v1/orders/{id}/request-draft-update | Request changes to a draft |
|
|
17
|
+
| [**request_order_update**](OrdersApi.md#request_order_update) | **POST** /api/v1/orders/{id}/request-update | Request changes to a delivery |
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
## approve_order
|
|
21
|
+
|
|
22
|
+
> <Order> approve_order(id, idempotency_key)
|
|
23
|
+
|
|
24
|
+
Approve an order's delivery
|
|
25
|
+
|
|
26
|
+
Approves the delivery of an order whose `pendingAction` is yours to review the delivery, as the web does. The order finishes and the seller is paid. It takes no body.
|
|
27
|
+
|
|
28
|
+
### Examples
|
|
29
|
+
|
|
30
|
+
```ruby
|
|
31
|
+
require 'time'
|
|
32
|
+
require 'growwer'
|
|
33
|
+
# setup authorization
|
|
34
|
+
Growwer.configure do |config|
|
|
35
|
+
# Configure Bearer authorization: apiKey
|
|
36
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
37
|
+
end
|
|
38
|
+
|
|
39
|
+
api_instance = Growwer::OrdersApi.new
|
|
40
|
+
id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String |
|
|
41
|
+
idempotency_key = 'idempotency_key_example' # String | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`.
|
|
42
|
+
|
|
43
|
+
begin
|
|
44
|
+
# Approve an order's delivery
|
|
45
|
+
result = api_instance.approve_order(id, idempotency_key)
|
|
46
|
+
p result
|
|
47
|
+
rescue Growwer::ApiError => e
|
|
48
|
+
puts "Error when calling OrdersApi->approve_order: #{e}"
|
|
49
|
+
end
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
#### Using the approve_order_with_http_info variant
|
|
53
|
+
|
|
54
|
+
This returns an Array which contains the response data, status code and headers.
|
|
55
|
+
|
|
56
|
+
> <Array(<Order>, Integer, Hash)> approve_order_with_http_info(id, idempotency_key)
|
|
57
|
+
|
|
58
|
+
```ruby
|
|
59
|
+
begin
|
|
60
|
+
# Approve an order's delivery
|
|
61
|
+
data, status_code, headers = api_instance.approve_order_with_http_info(id, idempotency_key)
|
|
62
|
+
p status_code # => 2xx
|
|
63
|
+
p headers # => { ... }
|
|
64
|
+
p data # => <Order>
|
|
65
|
+
rescue Growwer::ApiError => e
|
|
66
|
+
puts "Error when calling OrdersApi->approve_order_with_http_info: #{e}"
|
|
67
|
+
end
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
### Parameters
|
|
71
|
+
|
|
72
|
+
| Name | Type | Description | Notes |
|
|
73
|
+
| ---- | ---- | ----------- | ----- |
|
|
74
|
+
| **id** | **String** | | |
|
|
75
|
+
| **idempotency_key** | **String** | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`. | |
|
|
76
|
+
|
|
77
|
+
### Return type
|
|
78
|
+
|
|
79
|
+
[**Order**](Order.md)
|
|
80
|
+
|
|
81
|
+
### Authorization
|
|
82
|
+
|
|
83
|
+
[apiKey](../README.md#apiKey)
|
|
84
|
+
|
|
85
|
+
### HTTP request headers
|
|
86
|
+
|
|
87
|
+
- **Content-Type**: Not defined
|
|
88
|
+
- **Accept**: application/json
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
## approve_order_draft
|
|
92
|
+
|
|
93
|
+
> <Order> approve_order_draft(id, idempotency_key)
|
|
94
|
+
|
|
95
|
+
Approve a draft
|
|
96
|
+
|
|
97
|
+
Approves the draft of a post order whose `pendingAction` is yours to review the draft (GET /orders/{id}/draft downloads it), as the web does. The seller then publishes it. It takes no body.
|
|
98
|
+
|
|
99
|
+
### Examples
|
|
100
|
+
|
|
101
|
+
```ruby
|
|
102
|
+
require 'time'
|
|
103
|
+
require 'growwer'
|
|
104
|
+
# setup authorization
|
|
105
|
+
Growwer.configure do |config|
|
|
106
|
+
# Configure Bearer authorization: apiKey
|
|
107
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
108
|
+
end
|
|
109
|
+
|
|
110
|
+
api_instance = Growwer::OrdersApi.new
|
|
111
|
+
id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String |
|
|
112
|
+
idempotency_key = 'idempotency_key_example' # String | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`.
|
|
113
|
+
|
|
114
|
+
begin
|
|
115
|
+
# Approve a draft
|
|
116
|
+
result = api_instance.approve_order_draft(id, idempotency_key)
|
|
117
|
+
p result
|
|
118
|
+
rescue Growwer::ApiError => e
|
|
119
|
+
puts "Error when calling OrdersApi->approve_order_draft: #{e}"
|
|
120
|
+
end
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
#### Using the approve_order_draft_with_http_info variant
|
|
124
|
+
|
|
125
|
+
This returns an Array which contains the response data, status code and headers.
|
|
126
|
+
|
|
127
|
+
> <Array(<Order>, Integer, Hash)> approve_order_draft_with_http_info(id, idempotency_key)
|
|
128
|
+
|
|
129
|
+
```ruby
|
|
130
|
+
begin
|
|
131
|
+
# Approve a draft
|
|
132
|
+
data, status_code, headers = api_instance.approve_order_draft_with_http_info(id, idempotency_key)
|
|
133
|
+
p status_code # => 2xx
|
|
134
|
+
p headers # => { ... }
|
|
135
|
+
p data # => <Order>
|
|
136
|
+
rescue Growwer::ApiError => e
|
|
137
|
+
puts "Error when calling OrdersApi->approve_order_draft_with_http_info: #{e}"
|
|
138
|
+
end
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
### Parameters
|
|
142
|
+
|
|
143
|
+
| Name | Type | Description | Notes |
|
|
144
|
+
| ---- | ---- | ----------- | ----- |
|
|
145
|
+
| **id** | **String** | | |
|
|
146
|
+
| **idempotency_key** | **String** | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`. | |
|
|
147
|
+
|
|
148
|
+
### Return type
|
|
149
|
+
|
|
150
|
+
[**Order**](Order.md)
|
|
151
|
+
|
|
152
|
+
### Authorization
|
|
153
|
+
|
|
154
|
+
[apiKey](../README.md#apiKey)
|
|
155
|
+
|
|
156
|
+
### HTTP request headers
|
|
157
|
+
|
|
158
|
+
- **Content-Type**: Not defined
|
|
159
|
+
- **Accept**: application/json
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
## cancel_order
|
|
163
|
+
|
|
164
|
+
> <Order> cancel_order(id, idempotency_key, order_action_reason)
|
|
165
|
+
|
|
166
|
+
Cancel an order
|
|
167
|
+
|
|
168
|
+
Cancels an order the seller has not accepted yet (`state` `pending_acceptance`), as the web does. Its price returns to your wallet's available balance, and the seller is told your reason.
|
|
169
|
+
|
|
170
|
+
### Examples
|
|
171
|
+
|
|
172
|
+
```ruby
|
|
173
|
+
require 'time'
|
|
174
|
+
require 'growwer'
|
|
175
|
+
# setup authorization
|
|
176
|
+
Growwer.configure do |config|
|
|
177
|
+
# Configure Bearer authorization: apiKey
|
|
178
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
179
|
+
end
|
|
180
|
+
|
|
181
|
+
api_instance = Growwer::OrdersApi.new
|
|
182
|
+
id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String |
|
|
183
|
+
idempotency_key = 'idempotency_key_example' # String | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`.
|
|
184
|
+
order_action_reason = Growwer::OrderActionReason.new({reason: 'reason_example'}) # OrderActionReason |
|
|
185
|
+
|
|
186
|
+
begin
|
|
187
|
+
# Cancel an order
|
|
188
|
+
result = api_instance.cancel_order(id, idempotency_key, order_action_reason)
|
|
189
|
+
p result
|
|
190
|
+
rescue Growwer::ApiError => e
|
|
191
|
+
puts "Error when calling OrdersApi->cancel_order: #{e}"
|
|
192
|
+
end
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
#### Using the cancel_order_with_http_info variant
|
|
196
|
+
|
|
197
|
+
This returns an Array which contains the response data, status code and headers.
|
|
198
|
+
|
|
199
|
+
> <Array(<Order>, Integer, Hash)> cancel_order_with_http_info(id, idempotency_key, order_action_reason)
|
|
200
|
+
|
|
201
|
+
```ruby
|
|
202
|
+
begin
|
|
203
|
+
# Cancel an order
|
|
204
|
+
data, status_code, headers = api_instance.cancel_order_with_http_info(id, idempotency_key, order_action_reason)
|
|
205
|
+
p status_code # => 2xx
|
|
206
|
+
p headers # => { ... }
|
|
207
|
+
p data # => <Order>
|
|
208
|
+
rescue Growwer::ApiError => e
|
|
209
|
+
puts "Error when calling OrdersApi->cancel_order_with_http_info: #{e}"
|
|
210
|
+
end
|
|
211
|
+
```
|
|
212
|
+
|
|
213
|
+
### Parameters
|
|
214
|
+
|
|
215
|
+
| Name | Type | Description | Notes |
|
|
216
|
+
| ---- | ---- | ----------- | ----- |
|
|
217
|
+
| **id** | **String** | | |
|
|
218
|
+
| **idempotency_key** | **String** | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`. | |
|
|
219
|
+
| **order_action_reason** | [**OrderActionReason**](OrderActionReason.md) | | |
|
|
220
|
+
|
|
221
|
+
### Return type
|
|
222
|
+
|
|
223
|
+
[**Order**](Order.md)
|
|
224
|
+
|
|
225
|
+
### Authorization
|
|
226
|
+
|
|
227
|
+
[apiKey](../README.md#apiKey)
|
|
228
|
+
|
|
229
|
+
### HTTP request headers
|
|
230
|
+
|
|
231
|
+
- **Content-Type**: application/json
|
|
232
|
+
- **Accept**: application/json
|
|
233
|
+
|
|
234
|
+
|
|
235
|
+
## create_order
|
|
236
|
+
|
|
237
|
+
> <Order> create_order(idempotency_key, order_create_request)
|
|
238
|
+
|
|
239
|
+
Place an order
|
|
240
|
+
|
|
241
|
+
Places an order on a media for one of your projects and pays its price from your wallet's available balance, as ordering on the web does. Estimate the order first (POST /orders/estimate) and send the price it answers as `expectedPrice`: the order is placed only at that price. Placing the same order (same project, media, type and price) again within 5 seconds of one still in progress is refused with `duplicate_order`. Its `details.orderId` is the earlier order, or null when that order has finished or was deleted since. A proposed draft (`proposedDraftFileId`, from POST /files) is used up when the order is placed. If the order is then refused because another request changed your balance, the media or its price, or placed the same order, the file is used up all the same and the refusal's message says so: upload it again before retrying.
|
|
242
|
+
|
|
243
|
+
### Examples
|
|
244
|
+
|
|
245
|
+
```ruby
|
|
246
|
+
require 'time'
|
|
247
|
+
require 'growwer'
|
|
248
|
+
# setup authorization
|
|
249
|
+
Growwer.configure do |config|
|
|
250
|
+
# Configure Bearer authorization: apiKey
|
|
251
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
252
|
+
end
|
|
253
|
+
|
|
254
|
+
api_instance = Growwer::OrdersApi.new
|
|
255
|
+
idempotency_key = 'idempotency_key_example' # String | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`.
|
|
256
|
+
order_create_request = Growwer::OrderCreateRequest.new({type: 'post', project_id: 'project_id_example', media_id: 'media_id_example', briefing: Growwer::LinkAdditionOrderBriefingRequest.new({linking_from: 'linking_from_example', link: Growwer::OrderLinkRequest.new({type: 'dofollow'})}), expected_price: Growwer::Money.new({amount: 12500, currency: 'EUR'})}) # OrderCreateRequest |
|
|
257
|
+
|
|
258
|
+
begin
|
|
259
|
+
# Place an order
|
|
260
|
+
result = api_instance.create_order(idempotency_key, order_create_request)
|
|
261
|
+
p result
|
|
262
|
+
rescue Growwer::ApiError => e
|
|
263
|
+
puts "Error when calling OrdersApi->create_order: #{e}"
|
|
264
|
+
end
|
|
265
|
+
```
|
|
266
|
+
|
|
267
|
+
#### Using the create_order_with_http_info variant
|
|
268
|
+
|
|
269
|
+
This returns an Array which contains the response data, status code and headers.
|
|
270
|
+
|
|
271
|
+
> <Array(<Order>, Integer, Hash)> create_order_with_http_info(idempotency_key, order_create_request)
|
|
272
|
+
|
|
273
|
+
```ruby
|
|
274
|
+
begin
|
|
275
|
+
# Place an order
|
|
276
|
+
data, status_code, headers = api_instance.create_order_with_http_info(idempotency_key, order_create_request)
|
|
277
|
+
p status_code # => 2xx
|
|
278
|
+
p headers # => { ... }
|
|
279
|
+
p data # => <Order>
|
|
280
|
+
rescue Growwer::ApiError => e
|
|
281
|
+
puts "Error when calling OrdersApi->create_order_with_http_info: #{e}"
|
|
282
|
+
end
|
|
283
|
+
```
|
|
284
|
+
|
|
285
|
+
### Parameters
|
|
286
|
+
|
|
287
|
+
| Name | Type | Description | Notes |
|
|
288
|
+
| ---- | ---- | ----------- | ----- |
|
|
289
|
+
| **idempotency_key** | **String** | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`. | |
|
|
290
|
+
| **order_create_request** | [**OrderCreateRequest**](OrderCreateRequest.md) | | |
|
|
291
|
+
|
|
292
|
+
### Return type
|
|
293
|
+
|
|
294
|
+
[**Order**](Order.md)
|
|
295
|
+
|
|
296
|
+
### Authorization
|
|
297
|
+
|
|
298
|
+
[apiKey](../README.md#apiKey)
|
|
299
|
+
|
|
300
|
+
### HTTP request headers
|
|
301
|
+
|
|
302
|
+
- **Content-Type**: application/json
|
|
303
|
+
- **Accept**: application/json
|
|
304
|
+
|
|
305
|
+
|
|
306
|
+
## download_order_briefing
|
|
307
|
+
|
|
308
|
+
> File download_order_briefing(id)
|
|
309
|
+
|
|
310
|
+
Download the draft you attached to an order
|
|
311
|
+
|
|
312
|
+
The file you attached to the briefing of a post order. 404 when the order has none (`briefing.hasProposedDraft` is false) or the file cannot be read.
|
|
313
|
+
|
|
314
|
+
### Examples
|
|
315
|
+
|
|
316
|
+
```ruby
|
|
317
|
+
require 'time'
|
|
318
|
+
require 'growwer'
|
|
319
|
+
# setup authorization
|
|
320
|
+
Growwer.configure do |config|
|
|
321
|
+
# Configure Bearer authorization: apiKey
|
|
322
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
323
|
+
end
|
|
324
|
+
|
|
325
|
+
api_instance = Growwer::OrdersApi.new
|
|
326
|
+
id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String |
|
|
327
|
+
|
|
328
|
+
begin
|
|
329
|
+
# Download the draft you attached to an order
|
|
330
|
+
result = api_instance.download_order_briefing(id)
|
|
331
|
+
p result
|
|
332
|
+
rescue Growwer::ApiError => e
|
|
333
|
+
puts "Error when calling OrdersApi->download_order_briefing: #{e}"
|
|
334
|
+
end
|
|
335
|
+
```
|
|
336
|
+
|
|
337
|
+
#### Using the download_order_briefing_with_http_info variant
|
|
338
|
+
|
|
339
|
+
This returns an Array which contains the response data, status code and headers.
|
|
340
|
+
|
|
341
|
+
> <Array(File, Integer, Hash)> download_order_briefing_with_http_info(id)
|
|
342
|
+
|
|
343
|
+
```ruby
|
|
344
|
+
begin
|
|
345
|
+
# Download the draft you attached to an order
|
|
346
|
+
data, status_code, headers = api_instance.download_order_briefing_with_http_info(id)
|
|
347
|
+
p status_code # => 2xx
|
|
348
|
+
p headers # => { ... }
|
|
349
|
+
p data # => File
|
|
350
|
+
rescue Growwer::ApiError => e
|
|
351
|
+
puts "Error when calling OrdersApi->download_order_briefing_with_http_info: #{e}"
|
|
352
|
+
end
|
|
353
|
+
```
|
|
354
|
+
|
|
355
|
+
### Parameters
|
|
356
|
+
|
|
357
|
+
| Name | Type | Description | Notes |
|
|
358
|
+
| ---- | ---- | ----------- | ----- |
|
|
359
|
+
| **id** | **String** | | |
|
|
360
|
+
|
|
361
|
+
### Return type
|
|
362
|
+
|
|
363
|
+
**File**
|
|
364
|
+
|
|
365
|
+
### Authorization
|
|
366
|
+
|
|
367
|
+
[apiKey](../README.md#apiKey)
|
|
368
|
+
|
|
369
|
+
### HTTP request headers
|
|
370
|
+
|
|
371
|
+
- **Content-Type**: Not defined
|
|
372
|
+
- **Accept**: application/octet-stream, application/json
|
|
373
|
+
|
|
374
|
+
|
|
375
|
+
## download_order_draft
|
|
376
|
+
|
|
377
|
+
> File download_order_draft(id)
|
|
378
|
+
|
|
379
|
+
Download the draft of an order
|
|
380
|
+
|
|
381
|
+
The file of the current draft of a post order. 404 when the order has no draft file (`draft.hasFile` is false) or the file cannot be read.
|
|
382
|
+
|
|
383
|
+
### Examples
|
|
384
|
+
|
|
385
|
+
```ruby
|
|
386
|
+
require 'time'
|
|
387
|
+
require 'growwer'
|
|
388
|
+
# setup authorization
|
|
389
|
+
Growwer.configure do |config|
|
|
390
|
+
# Configure Bearer authorization: apiKey
|
|
391
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
392
|
+
end
|
|
393
|
+
|
|
394
|
+
api_instance = Growwer::OrdersApi.new
|
|
395
|
+
id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String |
|
|
396
|
+
|
|
397
|
+
begin
|
|
398
|
+
# Download the draft of an order
|
|
399
|
+
result = api_instance.download_order_draft(id)
|
|
400
|
+
p result
|
|
401
|
+
rescue Growwer::ApiError => e
|
|
402
|
+
puts "Error when calling OrdersApi->download_order_draft: #{e}"
|
|
403
|
+
end
|
|
404
|
+
```
|
|
405
|
+
|
|
406
|
+
#### Using the download_order_draft_with_http_info variant
|
|
407
|
+
|
|
408
|
+
This returns an Array which contains the response data, status code and headers.
|
|
409
|
+
|
|
410
|
+
> <Array(File, Integer, Hash)> download_order_draft_with_http_info(id)
|
|
411
|
+
|
|
412
|
+
```ruby
|
|
413
|
+
begin
|
|
414
|
+
# Download the draft of an order
|
|
415
|
+
data, status_code, headers = api_instance.download_order_draft_with_http_info(id)
|
|
416
|
+
p status_code # => 2xx
|
|
417
|
+
p headers # => { ... }
|
|
418
|
+
p data # => File
|
|
419
|
+
rescue Growwer::ApiError => e
|
|
420
|
+
puts "Error when calling OrdersApi->download_order_draft_with_http_info: #{e}"
|
|
421
|
+
end
|
|
422
|
+
```
|
|
423
|
+
|
|
424
|
+
### Parameters
|
|
425
|
+
|
|
426
|
+
| Name | Type | Description | Notes |
|
|
427
|
+
| ---- | ---- | ----------- | ----- |
|
|
428
|
+
| **id** | **String** | | |
|
|
429
|
+
|
|
430
|
+
### Return type
|
|
431
|
+
|
|
432
|
+
**File**
|
|
433
|
+
|
|
434
|
+
### Authorization
|
|
435
|
+
|
|
436
|
+
[apiKey](../README.md#apiKey)
|
|
437
|
+
|
|
438
|
+
### HTTP request headers
|
|
439
|
+
|
|
440
|
+
- **Content-Type**: Not defined
|
|
441
|
+
- **Accept**: application/octet-stream, application/json
|
|
442
|
+
|
|
443
|
+
|
|
444
|
+
## estimate_order
|
|
445
|
+
|
|
446
|
+
> <OrderEstimate> estimate_order(order_estimate_request)
|
|
447
|
+
|
|
448
|
+
Estimate an order
|
|
449
|
+
|
|
450
|
+
Checks and prices the order POST /orders would place with the same body, without `expectedPrice`, and compares the price with your wallet's available balance. Nothing is placed, charged or used up, so a read-only key may call it and it takes no Idempotency-Key. Send the `price` it answers as `expectedPrice` when you place the order. The estimate is refused for the same reasons as the order itself, except a balance that does not cover the price: that is answered here with `sufficientBalance: false` and the `missing` amount.
|
|
451
|
+
|
|
452
|
+
### Examples
|
|
453
|
+
|
|
454
|
+
```ruby
|
|
455
|
+
require 'time'
|
|
456
|
+
require 'growwer'
|
|
457
|
+
# setup authorization
|
|
458
|
+
Growwer.configure do |config|
|
|
459
|
+
# Configure Bearer authorization: apiKey
|
|
460
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
461
|
+
end
|
|
462
|
+
|
|
463
|
+
api_instance = Growwer::OrdersApi.new
|
|
464
|
+
order_estimate_request = Growwer::OrderEstimateRequest.new({type: 'post', project_id: 'project_id_example', media_id: 'media_id_example', briefing: Growwer::LinkAdditionOrderBriefingRequest.new({linking_from: 'linking_from_example', link: Growwer::OrderLinkRequest.new({type: 'dofollow'})})}) # OrderEstimateRequest |
|
|
465
|
+
|
|
466
|
+
begin
|
|
467
|
+
# Estimate an order
|
|
468
|
+
result = api_instance.estimate_order(order_estimate_request)
|
|
469
|
+
p result
|
|
470
|
+
rescue Growwer::ApiError => e
|
|
471
|
+
puts "Error when calling OrdersApi->estimate_order: #{e}"
|
|
472
|
+
end
|
|
473
|
+
```
|
|
474
|
+
|
|
475
|
+
#### Using the estimate_order_with_http_info variant
|
|
476
|
+
|
|
477
|
+
This returns an Array which contains the response data, status code and headers.
|
|
478
|
+
|
|
479
|
+
> <Array(<OrderEstimate>, Integer, Hash)> estimate_order_with_http_info(order_estimate_request)
|
|
480
|
+
|
|
481
|
+
```ruby
|
|
482
|
+
begin
|
|
483
|
+
# Estimate an order
|
|
484
|
+
data, status_code, headers = api_instance.estimate_order_with_http_info(order_estimate_request)
|
|
485
|
+
p status_code # => 2xx
|
|
486
|
+
p headers # => { ... }
|
|
487
|
+
p data # => <OrderEstimate>
|
|
488
|
+
rescue Growwer::ApiError => e
|
|
489
|
+
puts "Error when calling OrdersApi->estimate_order_with_http_info: #{e}"
|
|
490
|
+
end
|
|
491
|
+
```
|
|
492
|
+
|
|
493
|
+
### Parameters
|
|
494
|
+
|
|
495
|
+
| Name | Type | Description | Notes |
|
|
496
|
+
| ---- | ---- | ----------- | ----- |
|
|
497
|
+
| **order_estimate_request** | [**OrderEstimateRequest**](OrderEstimateRequest.md) | | |
|
|
498
|
+
|
|
499
|
+
### Return type
|
|
500
|
+
|
|
501
|
+
[**OrderEstimate**](OrderEstimate.md)
|
|
502
|
+
|
|
503
|
+
### Authorization
|
|
504
|
+
|
|
505
|
+
[apiKey](../README.md#apiKey)
|
|
506
|
+
|
|
507
|
+
### HTTP request headers
|
|
508
|
+
|
|
509
|
+
- **Content-Type**: application/json
|
|
510
|
+
- **Accept**: application/json
|
|
511
|
+
|
|
512
|
+
|
|
513
|
+
## get_order
|
|
514
|
+
|
|
515
|
+
> <Order> get_order(id)
|
|
516
|
+
|
|
517
|
+
Get an order
|
|
518
|
+
|
|
519
|
+
One order you bought, with its briefing, its draft and its state history.
|
|
520
|
+
|
|
521
|
+
### Examples
|
|
522
|
+
|
|
523
|
+
```ruby
|
|
524
|
+
require 'time'
|
|
525
|
+
require 'growwer'
|
|
526
|
+
# setup authorization
|
|
527
|
+
Growwer.configure do |config|
|
|
528
|
+
# Configure Bearer authorization: apiKey
|
|
529
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
530
|
+
end
|
|
531
|
+
|
|
532
|
+
api_instance = Growwer::OrdersApi.new
|
|
533
|
+
id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String |
|
|
534
|
+
|
|
535
|
+
begin
|
|
536
|
+
# Get an order
|
|
537
|
+
result = api_instance.get_order(id)
|
|
538
|
+
p result
|
|
539
|
+
rescue Growwer::ApiError => e
|
|
540
|
+
puts "Error when calling OrdersApi->get_order: #{e}"
|
|
541
|
+
end
|
|
542
|
+
```
|
|
543
|
+
|
|
544
|
+
#### Using the get_order_with_http_info variant
|
|
545
|
+
|
|
546
|
+
This returns an Array which contains the response data, status code and headers.
|
|
547
|
+
|
|
548
|
+
> <Array(<Order>, Integer, Hash)> get_order_with_http_info(id)
|
|
549
|
+
|
|
550
|
+
```ruby
|
|
551
|
+
begin
|
|
552
|
+
# Get an order
|
|
553
|
+
data, status_code, headers = api_instance.get_order_with_http_info(id)
|
|
554
|
+
p status_code # => 2xx
|
|
555
|
+
p headers # => { ... }
|
|
556
|
+
p data # => <Order>
|
|
557
|
+
rescue Growwer::ApiError => e
|
|
558
|
+
puts "Error when calling OrdersApi->get_order_with_http_info: #{e}"
|
|
559
|
+
end
|
|
560
|
+
```
|
|
561
|
+
|
|
562
|
+
### Parameters
|
|
563
|
+
|
|
564
|
+
| Name | Type | Description | Notes |
|
|
565
|
+
| ---- | ---- | ----------- | ----- |
|
|
566
|
+
| **id** | **String** | | |
|
|
567
|
+
|
|
568
|
+
### Return type
|
|
569
|
+
|
|
570
|
+
[**Order**](Order.md)
|
|
571
|
+
|
|
572
|
+
### Authorization
|
|
573
|
+
|
|
574
|
+
[apiKey](../README.md#apiKey)
|
|
575
|
+
|
|
576
|
+
### HTTP request headers
|
|
577
|
+
|
|
578
|
+
- **Content-Type**: Not defined
|
|
579
|
+
- **Accept**: application/json
|
|
580
|
+
|
|
581
|
+
|
|
582
|
+
## list_orders
|
|
583
|
+
|
|
584
|
+
> <ListOrders200Response> list_orders(opts)
|
|
585
|
+
|
|
586
|
+
List your orders
|
|
587
|
+
|
|
588
|
+
The orders you bought, newest first by default. To follow your orders, poll with `sort=updatedAt` and `updatedSince` set to the `updatedAt` of the last order you saw: an order moves to the end of that list each time it changes state.
|
|
589
|
+
|
|
590
|
+
### Examples
|
|
591
|
+
|
|
592
|
+
```ruby
|
|
593
|
+
require 'time'
|
|
594
|
+
require 'growwer'
|
|
595
|
+
# setup authorization
|
|
596
|
+
Growwer.configure do |config|
|
|
597
|
+
# Configure Bearer authorization: apiKey
|
|
598
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
599
|
+
end
|
|
600
|
+
|
|
601
|
+
api_instance = Growwer::OrdersApi.new
|
|
602
|
+
opts = {
|
|
603
|
+
project_id: '38400000-8cf0-11bd-b23e-10b96e4ef00d', # String | Only the orders of this project of yours.
|
|
604
|
+
media_id: '38400000-8cf0-11bd-b23e-10b96e4ef00d', # String | Only the orders on this media.
|
|
605
|
+
state: 'pending_acceptance,pending_order_delivery', # String | Only the orders in one of these states, comma-separated. An unknown state is refused with 422 and the list of valid ones.
|
|
606
|
+
updated_since: Time.parse('2013-10-20T19:20:30+01:00'), # Time | Only the orders whose `updatedAt` is at or after this instant, an ISO-8601 date-time with its offset (send `+` as `%2B`).
|
|
607
|
+
sort: '-createdAt', # String | `-createdAt`, newest first, or `updatedAt`, least recently changed first. Orders of the same instant come in id order.
|
|
608
|
+
limit: 56, # Integer | Orders per page, 1 to 100.
|
|
609
|
+
offset: 56 # Integer | Orders to skip.
|
|
610
|
+
}
|
|
611
|
+
|
|
612
|
+
begin
|
|
613
|
+
# List your orders
|
|
614
|
+
result = api_instance.list_orders(opts)
|
|
615
|
+
p result
|
|
616
|
+
rescue Growwer::ApiError => e
|
|
617
|
+
puts "Error when calling OrdersApi->list_orders: #{e}"
|
|
618
|
+
end
|
|
619
|
+
```
|
|
620
|
+
|
|
621
|
+
#### Using the list_orders_with_http_info variant
|
|
622
|
+
|
|
623
|
+
This returns an Array which contains the response data, status code and headers.
|
|
624
|
+
|
|
625
|
+
> <Array(<ListOrders200Response>, Integer, Hash)> list_orders_with_http_info(opts)
|
|
626
|
+
|
|
627
|
+
```ruby
|
|
628
|
+
begin
|
|
629
|
+
# List your orders
|
|
630
|
+
data, status_code, headers = api_instance.list_orders_with_http_info(opts)
|
|
631
|
+
p status_code # => 2xx
|
|
632
|
+
p headers # => { ... }
|
|
633
|
+
p data # => <ListOrders200Response>
|
|
634
|
+
rescue Growwer::ApiError => e
|
|
635
|
+
puts "Error when calling OrdersApi->list_orders_with_http_info: #{e}"
|
|
636
|
+
end
|
|
637
|
+
```
|
|
638
|
+
|
|
639
|
+
### Parameters
|
|
640
|
+
|
|
641
|
+
| Name | Type | Description | Notes |
|
|
642
|
+
| ---- | ---- | ----------- | ----- |
|
|
643
|
+
| **project_id** | **String** | Only the orders of this project of yours. | [optional] |
|
|
644
|
+
| **media_id** | **String** | Only the orders on this media. | [optional] |
|
|
645
|
+
| **state** | **String** | Only the orders in one of these states, comma-separated. An unknown state is refused with 422 and the list of valid ones. | [optional] |
|
|
646
|
+
| **updated_since** | **Time** | Only the orders whose `updatedAt` is at or after this instant, an ISO-8601 date-time with its offset (send `+` as `%2B`). | [optional] |
|
|
647
|
+
| **sort** | **String** | `-createdAt`, newest first, or `updatedAt`, least recently changed first. Orders of the same instant come in id order. | [optional][default to '-createdAt'] |
|
|
648
|
+
| **limit** | **Integer** | Orders per page, 1 to 100. | [optional][default to 20] |
|
|
649
|
+
| **offset** | **Integer** | Orders to skip. | [optional][default to 0] |
|
|
650
|
+
|
|
651
|
+
### Return type
|
|
652
|
+
|
|
653
|
+
[**ListOrders200Response**](ListOrders200Response.md)
|
|
654
|
+
|
|
655
|
+
### Authorization
|
|
656
|
+
|
|
657
|
+
[apiKey](../README.md#apiKey)
|
|
658
|
+
|
|
659
|
+
### HTTP request headers
|
|
660
|
+
|
|
661
|
+
- **Content-Type**: Not defined
|
|
662
|
+
- **Accept**: application/json
|
|
663
|
+
|
|
664
|
+
|
|
665
|
+
## request_order_draft_update
|
|
666
|
+
|
|
667
|
+
> <Order> request_order_draft_update(id, idempotency_key, order_action_reason)
|
|
668
|
+
|
|
669
|
+
Request changes to a draft
|
|
670
|
+
|
|
671
|
+
Asks the seller to change the draft of a post order whose `pendingAction` is yours to review the draft, as the web does. The seller is told your reason.
|
|
672
|
+
|
|
673
|
+
### Examples
|
|
674
|
+
|
|
675
|
+
```ruby
|
|
676
|
+
require 'time'
|
|
677
|
+
require 'growwer'
|
|
678
|
+
# setup authorization
|
|
679
|
+
Growwer.configure do |config|
|
|
680
|
+
# Configure Bearer authorization: apiKey
|
|
681
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
682
|
+
end
|
|
683
|
+
|
|
684
|
+
api_instance = Growwer::OrdersApi.new
|
|
685
|
+
id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String |
|
|
686
|
+
idempotency_key = 'idempotency_key_example' # String | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`.
|
|
687
|
+
order_action_reason = Growwer::OrderActionReason.new({reason: 'reason_example'}) # OrderActionReason |
|
|
688
|
+
|
|
689
|
+
begin
|
|
690
|
+
# Request changes to a draft
|
|
691
|
+
result = api_instance.request_order_draft_update(id, idempotency_key, order_action_reason)
|
|
692
|
+
p result
|
|
693
|
+
rescue Growwer::ApiError => e
|
|
694
|
+
puts "Error when calling OrdersApi->request_order_draft_update: #{e}"
|
|
695
|
+
end
|
|
696
|
+
```
|
|
697
|
+
|
|
698
|
+
#### Using the request_order_draft_update_with_http_info variant
|
|
699
|
+
|
|
700
|
+
This returns an Array which contains the response data, status code and headers.
|
|
701
|
+
|
|
702
|
+
> <Array(<Order>, Integer, Hash)> request_order_draft_update_with_http_info(id, idempotency_key, order_action_reason)
|
|
703
|
+
|
|
704
|
+
```ruby
|
|
705
|
+
begin
|
|
706
|
+
# Request changes to a draft
|
|
707
|
+
data, status_code, headers = api_instance.request_order_draft_update_with_http_info(id, idempotency_key, order_action_reason)
|
|
708
|
+
p status_code # => 2xx
|
|
709
|
+
p headers # => { ... }
|
|
710
|
+
p data # => <Order>
|
|
711
|
+
rescue Growwer::ApiError => e
|
|
712
|
+
puts "Error when calling OrdersApi->request_order_draft_update_with_http_info: #{e}"
|
|
713
|
+
end
|
|
714
|
+
```
|
|
715
|
+
|
|
716
|
+
### Parameters
|
|
717
|
+
|
|
718
|
+
| Name | Type | Description | Notes |
|
|
719
|
+
| ---- | ---- | ----------- | ----- |
|
|
720
|
+
| **id** | **String** | | |
|
|
721
|
+
| **idempotency_key** | **String** | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`. | |
|
|
722
|
+
| **order_action_reason** | [**OrderActionReason**](OrderActionReason.md) | | |
|
|
723
|
+
|
|
724
|
+
### Return type
|
|
725
|
+
|
|
726
|
+
[**Order**](Order.md)
|
|
727
|
+
|
|
728
|
+
### Authorization
|
|
729
|
+
|
|
730
|
+
[apiKey](../README.md#apiKey)
|
|
731
|
+
|
|
732
|
+
### HTTP request headers
|
|
733
|
+
|
|
734
|
+
- **Content-Type**: application/json
|
|
735
|
+
- **Accept**: application/json
|
|
736
|
+
|
|
737
|
+
|
|
738
|
+
## request_order_update
|
|
739
|
+
|
|
740
|
+
> <Order> request_order_update(id, idempotency_key, order_action_reason)
|
|
741
|
+
|
|
742
|
+
Request changes to a delivery
|
|
743
|
+
|
|
744
|
+
Asks the seller to change the delivery of an order whose `pendingAction` is yours to review the delivery, as the web does. The seller is told your reason.
|
|
745
|
+
|
|
746
|
+
### Examples
|
|
747
|
+
|
|
748
|
+
```ruby
|
|
749
|
+
require 'time'
|
|
750
|
+
require 'growwer'
|
|
751
|
+
# setup authorization
|
|
752
|
+
Growwer.configure do |config|
|
|
753
|
+
# Configure Bearer authorization: apiKey
|
|
754
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
755
|
+
end
|
|
756
|
+
|
|
757
|
+
api_instance = Growwer::OrdersApi.new
|
|
758
|
+
id = '38400000-8cf0-11bd-b23e-10b96e4ef00d' # String |
|
|
759
|
+
idempotency_key = 'idempotency_key_example' # String | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`.
|
|
760
|
+
order_action_reason = Growwer::OrderActionReason.new({reason: 'reason_example'}) # OrderActionReason |
|
|
761
|
+
|
|
762
|
+
begin
|
|
763
|
+
# Request changes to a delivery
|
|
764
|
+
result = api_instance.request_order_update(id, idempotency_key, order_action_reason)
|
|
765
|
+
p result
|
|
766
|
+
rescue Growwer::ApiError => e
|
|
767
|
+
puts "Error when calling OrdersApi->request_order_update: #{e}"
|
|
768
|
+
end
|
|
769
|
+
```
|
|
770
|
+
|
|
771
|
+
#### Using the request_order_update_with_http_info variant
|
|
772
|
+
|
|
773
|
+
This returns an Array which contains the response data, status code and headers.
|
|
774
|
+
|
|
775
|
+
> <Array(<Order>, Integer, Hash)> request_order_update_with_http_info(id, idempotency_key, order_action_reason)
|
|
776
|
+
|
|
777
|
+
```ruby
|
|
778
|
+
begin
|
|
779
|
+
# Request changes to a delivery
|
|
780
|
+
data, status_code, headers = api_instance.request_order_update_with_http_info(id, idempotency_key, order_action_reason)
|
|
781
|
+
p status_code # => 2xx
|
|
782
|
+
p headers # => { ... }
|
|
783
|
+
p data # => <Order>
|
|
784
|
+
rescue Growwer::ApiError => e
|
|
785
|
+
puts "Error when calling OrdersApi->request_order_update_with_http_info: #{e}"
|
|
786
|
+
end
|
|
787
|
+
```
|
|
788
|
+
|
|
789
|
+
### Parameters
|
|
790
|
+
|
|
791
|
+
| Name | Type | Description | Notes |
|
|
792
|
+
| ---- | ---- | ----------- | ----- |
|
|
793
|
+
| **id** | **String** | | |
|
|
794
|
+
| **idempotency_key** | **String** | A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters without spaces (`!` to `~`); any other value answers 400 `invalid_idempotency_key`. | |
|
|
795
|
+
| **order_action_reason** | [**OrderActionReason**](OrderActionReason.md) | | |
|
|
796
|
+
|
|
797
|
+
### Return type
|
|
798
|
+
|
|
799
|
+
[**Order**](Order.md)
|
|
800
|
+
|
|
801
|
+
### Authorization
|
|
802
|
+
|
|
803
|
+
[apiKey](../README.md#apiKey)
|
|
804
|
+
|
|
805
|
+
### HTTP request headers
|
|
806
|
+
|
|
807
|
+
- **Content-Type**: application/json
|
|
808
|
+
- **Accept**: application/json
|
|
809
|
+
|