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
|
@@ -0,0 +1,213 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Growwer API
|
|
3
|
+
|
|
4
|
+
#The Growwer customer API. Authenticate every call with an API key created on your profile page, sent as `Authorization: Bearer <key>`. A read key can call every GET operation; writes need a read and write key and an `Idempotency-Key` header. Idempotency: use a new `Idempotency-Key` (1 to 255 printable ASCII characters) for each operation and reuse it only to retry that same operation. Keys belong to your account, not to one API key. - A successful write is stored for 30 days: a retry with the same key and the same request replays its response with `Idempotent-Replayed: true` and does nothing again. - A refused write (4xx) has no effect and releases its key: once you fix the cause, retry with the same key and the write runs. - A failed write (5xx) may have taken effect, so it is never run again under its key: a retry gets 409 `idempotency_outcome_unknown`. Check whether it took effect before retrying with a new key. - A retry while the first request is still running gets 409 `idempotency_request_in_progress`. A request still running after 5 minutes is treated as failed: a retry gets 409 `idempotency_outcome_unknown`. - The same key with a different request (method, path, query or body) gets 409 `idempotency_key_reused`. A write without the header gets 400 `idempotency_key_required`. Every response carries `X-Request-Id`. Errors share one shape, `{code, message, requestId, details?}`. Money is integer cents plus a currency code and dates are ISO-8601.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1
|
|
7
|
+
Contact: support@growwer.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.24.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'spec_helper'
|
|
14
|
+
require 'json'
|
|
15
|
+
|
|
16
|
+
# Unit tests for Growwer::CatalogueApi
|
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
|
18
|
+
# Please update as you see appropriate
|
|
19
|
+
describe 'CatalogueApi' do
|
|
20
|
+
before do
|
|
21
|
+
# run before each test
|
|
22
|
+
@api_instance = Growwer::CatalogueApi.new
|
|
23
|
+
end
|
|
24
|
+
|
|
25
|
+
after do
|
|
26
|
+
# run after each test
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
describe 'test an instance of CatalogueApi' do
|
|
30
|
+
it 'should create an instance of CatalogueApi' do
|
|
31
|
+
expect(@api_instance).to be_instance_of(Growwer::CatalogueApi)
|
|
32
|
+
end
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
# unit tests for discard_media
|
|
36
|
+
# Discard a media for a project
|
|
37
|
+
# Discards a media for one of your projects, as the web does. Discarding it again changes nothing. The media must be one the catalogue shows for the project: another media, including one of your own as a seller, is answered as not found.
|
|
38
|
+
# @param id The project.
|
|
39
|
+
# @param media_id The media.
|
|
40
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
41
|
+
# @param [Hash] opts the optional parameters
|
|
42
|
+
# @return [nil]
|
|
43
|
+
describe 'discard_media test' do
|
|
44
|
+
it 'should work' do
|
|
45
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
46
|
+
end
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
# unit tests for favourite_media
|
|
50
|
+
# Add a media to the favourites of a project
|
|
51
|
+
# Marks a media as a favourite of one of your projects, as the heart on the web does. Adding a favourite again changes nothing. The media must be one the catalogue shows for the project: another media, including one of your own as a seller, is answered as not found.
|
|
52
|
+
# @param id The project.
|
|
53
|
+
# @param media_id The media.
|
|
54
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
55
|
+
# @param [Hash] opts the optional parameters
|
|
56
|
+
# @return [nil]
|
|
57
|
+
describe 'favourite_media test' do
|
|
58
|
+
it 'should work' do
|
|
59
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
60
|
+
end
|
|
61
|
+
end
|
|
62
|
+
|
|
63
|
+
# unit tests for get_catalogue_media
|
|
64
|
+
# Get a media
|
|
65
|
+
# One media of the catalogue: an active, public media. A media you have ordered is always readable, even if it has since left the catalogue, and is open to every account. Otherwise the catalogue is open to accounts with recent completed orders (see `catalogue.eligible` on GET /me), and the media counts towards the distinct medias the account may see per day (UTC). For the media's state in one of your projects, search the project with GET /projects/{id}/medias.
|
|
66
|
+
# @param id The media.
|
|
67
|
+
# @param [Hash] opts the optional parameters
|
|
68
|
+
# @return [CatalogueMedia]
|
|
69
|
+
describe 'get_catalogue_media test' do
|
|
70
|
+
it 'should work' do
|
|
71
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
72
|
+
end
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
# unit tests for list_flash_offers
|
|
76
|
+
# List flash offers
|
|
77
|
+
# The medias on a flash offer, a time-limited discount, in the catalogue of one of your projects. It is GET /projects/{id}/medias with `flashOffer=true`, and takes the same parameters except `flashOffer` and `savedFilterId`. The catalogue access and the daily distinct-media limit of that operation apply.
|
|
78
|
+
# @param project_id The project to search flash offers for.
|
|
79
|
+
# @param [Hash] opts the optional parameters
|
|
80
|
+
# @option opts [String] :source Which of the project's medias to search: `all` (the default), `recommended` (those Growwer recommends for the project), or those you marked `favourite`, `discarded` or `requested`, or `bought` for the project. Do not combine it with the parameter of the same state.
|
|
81
|
+
# @option opts [String] :sort The order. Without it, the web's default order: medias on the project's topic and language first, then best sellers and medias with more published orders. Ties are always broken by media id, so pages never overlap. `-growwerRank`: best match first; `postPrice`, `linkAdditionPrice`: cheapest first; `matchedAt`, `-matchedAt`: when Growwer matched the media with the project; `-traffic`, `-domainRating`, `-referringDomains`: highest first; `linkedToReferringRatio`: lowest first.
|
|
82
|
+
# @option opts [String] :domain Medias whose domain contains this text, 1 to 255 characters.
|
|
83
|
+
# @option opts [String] :website_type A comma-separated list of website types: `blog`, `press`.
|
|
84
|
+
# @option opts [String] :language A comma-separated list of language codes, as in GET /vocabulary.
|
|
85
|
+
# @option opts [String] :country A comma-separated list of country codes, as in GET /vocabulary.
|
|
86
|
+
# @option opts [String] :topics A comma-separated list of topic ids, as in GET /vocabulary: medias on any of them.
|
|
87
|
+
# @option opts [Boolean] :not_banned_topics Leave out medias that refuse the topic of the project. Only `true` applies it; omit it otherwise.
|
|
88
|
+
# @option opts [Integer] :min_traffic Minimum monthly organic traffic.
|
|
89
|
+
# @option opts [Integer] :max_traffic Maximum monthly organic traffic.
|
|
90
|
+
# @option opts [Boolean] :traffic_trend_upward Medias whose traffic is growing. Only `true` applies it; omit it otherwise.
|
|
91
|
+
# @option opts [Integer] :min_domain_rating Minimum domain rating, 0 to 100.
|
|
92
|
+
# @option opts [Integer] :max_domain_rating Maximum domain rating, 0 to 100.
|
|
93
|
+
# @option opts [Float] :min_linked_to_referring_ratio Minimum ratio of linked domains to referring domains, such as 0.5.
|
|
94
|
+
# @option opts [Float] :max_linked_to_referring_ratio Maximum ratio of linked domains to referring domains, such as 1.5.
|
|
95
|
+
# @option opts [Integer] :min_post_price Minimum post price, in cents.
|
|
96
|
+
# @option opts [Integer] :max_post_price Maximum post price, in cents.
|
|
97
|
+
# @option opts [String] :post_link_type A comma-separated list of link types the post offer gives: `dofollow`, `nofollow`, `citation`.
|
|
98
|
+
# @option opts [String] :promoted_social_network A comma-separated list of social networks the media promotes posts on: `twitter`, `instagram`, `facebook`, `pinterest`, `tumblr`, `newsletter`.
|
|
99
|
+
# @option opts [Boolean] :without_advertising_label Medias that never label posts as advertising. Only `true` applies it; omit it otherwise.
|
|
100
|
+
# @option opts [Boolean] :homepage_listing Medias that offer listing the post on their homepage. Only `true` applies it; omit it otherwise.
|
|
101
|
+
# @option opts [Boolean] :has_link_addition Medias that offer adding a link to an existing article. Only `true` applies it; omit it otherwise.
|
|
102
|
+
# @option opts [Integer] :min_link_addition_price Minimum link addition price, in cents.
|
|
103
|
+
# @option opts [Integer] :max_link_addition_price Maximum link addition price, in cents.
|
|
104
|
+
# @option opts [String] :link_addition_link_type A comma-separated list of link types the link addition offer gives: `dofollow`, `nofollow`, `citation`.
|
|
105
|
+
# @option opts [Boolean] :recommended `true`: only the medias Growwer recommends for the project; `false`: only the others.
|
|
106
|
+
# @option opts [Boolean] :favourite `true`: only your favourites for the project; `false`: leave them out.
|
|
107
|
+
# @option opts [Boolean] :requested `true`: only the medias you requested for the project; `false`: leave them out.
|
|
108
|
+
# @option opts [Boolean] :bought `true`: only medias you bought for the project; `false`: leave them out.
|
|
109
|
+
# @option opts [Boolean] :discarded `true`: only the medias you discarded for the project; `false`: leave them out.
|
|
110
|
+
# @option opts [Boolean] :new Medias Growwer matched with the project recently. Only `true` applies it; omit it otherwise.
|
|
111
|
+
# @option opts [String] :ranks_goal_keyword A comma-separated list of keyword origins: medias that rank for a keyword of the project from any of them. `user`: your keywords; `publicGenerated`: keywords Growwer found for the project.
|
|
112
|
+
# @option opts [String] :ranks_ai_keyword A comma-separated list of AI answer engines: medias cited for a keyword of the project by any of them. `googleAiOverview`, `chatgpt`, `googleAiMode`.
|
|
113
|
+
# @option opts [Integer] :limit Medias per page, 1 to 100.
|
|
114
|
+
# @option opts [Integer] :offset Medias to skip, at most 99900.
|
|
115
|
+
# @return [ListFlashOffers200Response]
|
|
116
|
+
describe 'list_flash_offers test' do
|
|
117
|
+
it 'should work' do
|
|
118
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
119
|
+
end
|
|
120
|
+
end
|
|
121
|
+
|
|
122
|
+
# unit tests for request_medias
|
|
123
|
+
# Request specific medias for a project
|
|
124
|
+
# Asks Growwer to find the medias of these domains for one of your projects, as the \"request specific domains\" form on the web does. Each entry may be a domain or a URL; it is read as its full domain, lowercased. Repeated domains are requested once, and a domain already requested changes nothing. Up to 200 distinct domains per call. They then appear in the project's catalogue with `project.requested` true (`requested=true` on GET /projects/{id}/medias) once Growwer lists them.
|
|
125
|
+
# @param id The project.
|
|
126
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
127
|
+
# @param request_medias_request
|
|
128
|
+
# @param [Hash] opts the optional parameters
|
|
129
|
+
# @return [RequestMedias201Response]
|
|
130
|
+
describe 'request_medias test' do
|
|
131
|
+
it 'should work' do
|
|
132
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
133
|
+
end
|
|
134
|
+
end
|
|
135
|
+
|
|
136
|
+
# unit tests for search_project_medias
|
|
137
|
+
# Search the catalogue for a project
|
|
138
|
+
# The medias the catalogue offers for one of your projects, as the web lists them, with each media's state in the project. Filter with the parameters below, which all combine, or apply one of your saved filters with `savedFilterId` alone. The catalogue is open to accounts with recent completed orders (see `catalogue.eligible` on GET /me), and each account can see a limited number of distinct medias per day (UTC) across the catalogue operations; medias seen again the same day are free.
|
|
139
|
+
# @param id The project.
|
|
140
|
+
# @param [Hash] opts the optional parameters
|
|
141
|
+
# @option opts [String] :source Which of the project's medias to search: `all` (the default), `recommended` (those Growwer recommends for the project), or those you marked `favourite`, `discarded` or `requested`, or `bought` for the project. Do not combine it with the parameter of the same state.
|
|
142
|
+
# @option opts [String] :sort The order. Without it, the web's default order: medias on the project's topic and language first, then best sellers and medias with more published orders. Ties are always broken by media id, so pages never overlap. `-growwerRank`: best match first; `postPrice`, `linkAdditionPrice`: cheapest first; `matchedAt`, `-matchedAt`: when Growwer matched the media with the project; `-traffic`, `-domainRating`, `-referringDomains`: highest first; `linkedToReferringRatio`: lowest first.
|
|
143
|
+
# @option opts [String] :saved_filter_id Apply one of your saved filters of this project, including one saved on the web, instead of the other parameters. Do not combine it with any filter, `source` or `sort`. A filter saved on the web that uses a filter the API does not support is refused with 422 `saved_filter_unsupported`.
|
|
144
|
+
# @option opts [String] :domain Medias whose domain contains this text, 1 to 255 characters.
|
|
145
|
+
# @option opts [String] :website_type A comma-separated list of website types: `blog`, `press`.
|
|
146
|
+
# @option opts [String] :language A comma-separated list of language codes, as in GET /vocabulary.
|
|
147
|
+
# @option opts [String] :country A comma-separated list of country codes, as in GET /vocabulary.
|
|
148
|
+
# @option opts [String] :topics A comma-separated list of topic ids, as in GET /vocabulary: medias on any of them.
|
|
149
|
+
# @option opts [Boolean] :not_banned_topics Leave out medias that refuse the topic of the project. Only `true` applies it; omit it otherwise.
|
|
150
|
+
# @option opts [Integer] :min_traffic Minimum monthly organic traffic.
|
|
151
|
+
# @option opts [Integer] :max_traffic Maximum monthly organic traffic.
|
|
152
|
+
# @option opts [Boolean] :traffic_trend_upward Medias whose traffic is growing. Only `true` applies it; omit it otherwise.
|
|
153
|
+
# @option opts [Integer] :min_domain_rating Minimum domain rating, 0 to 100.
|
|
154
|
+
# @option opts [Integer] :max_domain_rating Maximum domain rating, 0 to 100.
|
|
155
|
+
# @option opts [Float] :min_linked_to_referring_ratio Minimum ratio of linked domains to referring domains, such as 0.5.
|
|
156
|
+
# @option opts [Float] :max_linked_to_referring_ratio Maximum ratio of linked domains to referring domains, such as 1.5.
|
|
157
|
+
# @option opts [Integer] :min_post_price Minimum post price, in cents.
|
|
158
|
+
# @option opts [Integer] :max_post_price Maximum post price, in cents.
|
|
159
|
+
# @option opts [String] :post_link_type A comma-separated list of link types the post offer gives: `dofollow`, `nofollow`, `citation`.
|
|
160
|
+
# @option opts [String] :promoted_social_network A comma-separated list of social networks the media promotes posts on: `twitter`, `instagram`, `facebook`, `pinterest`, `tumblr`, `newsletter`.
|
|
161
|
+
# @option opts [Boolean] :without_advertising_label Medias that never label posts as advertising. Only `true` applies it; omit it otherwise.
|
|
162
|
+
# @option opts [Boolean] :homepage_listing Medias that offer listing the post on their homepage. Only `true` applies it; omit it otherwise.
|
|
163
|
+
# @option opts [Boolean] :has_link_addition Medias that offer adding a link to an existing article. Only `true` applies it; omit it otherwise.
|
|
164
|
+
# @option opts [Integer] :min_link_addition_price Minimum link addition price, in cents.
|
|
165
|
+
# @option opts [Integer] :max_link_addition_price Maximum link addition price, in cents.
|
|
166
|
+
# @option opts [String] :link_addition_link_type A comma-separated list of link types the link addition offer gives: `dofollow`, `nofollow`, `citation`.
|
|
167
|
+
# @option opts [Boolean] :recommended `true`: only the medias Growwer recommends for the project; `false`: only the others.
|
|
168
|
+
# @option opts [Boolean] :favourite `true`: only your favourites for the project; `false`: leave them out.
|
|
169
|
+
# @option opts [Boolean] :requested `true`: only the medias you requested for the project; `false`: leave them out.
|
|
170
|
+
# @option opts [Boolean] :flash_offer `true`: only medias with a flash offer running; `false`: leave them out.
|
|
171
|
+
# @option opts [Boolean] :bought `true`: only medias you bought for the project; `false`: leave them out.
|
|
172
|
+
# @option opts [Boolean] :discarded `true`: only the medias you discarded for the project; `false`: leave them out.
|
|
173
|
+
# @option opts [Boolean] :new Medias Growwer matched with the project recently. Only `true` applies it; omit it otherwise.
|
|
174
|
+
# @option opts [String] :ranks_goal_keyword A comma-separated list of keyword origins: medias that rank for a keyword of the project from any of them. `user`: your keywords; `publicGenerated`: keywords Growwer found for the project.
|
|
175
|
+
# @option opts [String] :ranks_ai_keyword A comma-separated list of AI answer engines: medias cited for a keyword of the project by any of them. `googleAiOverview`, `chatgpt`, `googleAiMode`.
|
|
176
|
+
# @option opts [Integer] :limit Medias per page, 1 to 100.
|
|
177
|
+
# @option opts [Integer] :offset Medias to skip, at most 99900.
|
|
178
|
+
# @return [ListFlashOffers200Response]
|
|
179
|
+
describe 'search_project_medias test' do
|
|
180
|
+
it 'should work' do
|
|
181
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
182
|
+
end
|
|
183
|
+
end
|
|
184
|
+
|
|
185
|
+
# unit tests for undiscard_media
|
|
186
|
+
# Restore a discarded media for a project
|
|
187
|
+
# Restores a media you discarded for one of your projects. Restoring one that is not discarded changes nothing. It works for any media, even one the catalogue no longer shows.
|
|
188
|
+
# @param id The project.
|
|
189
|
+
# @param media_id The media.
|
|
190
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
191
|
+
# @param [Hash] opts the optional parameters
|
|
192
|
+
# @return [nil]
|
|
193
|
+
describe 'undiscard_media test' do
|
|
194
|
+
it 'should work' do
|
|
195
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
196
|
+
end
|
|
197
|
+
end
|
|
198
|
+
|
|
199
|
+
# unit tests for unfavourite_media
|
|
200
|
+
# Remove a media from the favourites of a project
|
|
201
|
+
# Removes a media from the favourites of one of your projects. Removing one that is not a favourite changes nothing. It works for any media, even one the catalogue no longer shows.
|
|
202
|
+
# @param id The project.
|
|
203
|
+
# @param media_id The media.
|
|
204
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
205
|
+
# @param [Hash] opts the optional parameters
|
|
206
|
+
# @return [nil]
|
|
207
|
+
describe 'unfavourite_media test' do
|
|
208
|
+
it 'should work' do
|
|
209
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
210
|
+
end
|
|
211
|
+
end
|
|
212
|
+
|
|
213
|
+
end
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Growwer API
|
|
3
|
+
|
|
4
|
+
#The Growwer customer API. Authenticate every call with an API key created on your profile page, sent as `Authorization: Bearer <key>`. A read key can call every GET operation; writes need a read and write key and an `Idempotency-Key` header. Idempotency: use a new `Idempotency-Key` (1 to 255 printable ASCII characters) for each operation and reuse it only to retry that same operation. Keys belong to your account, not to one API key. - A successful write is stored for 30 days: a retry with the same key and the same request replays its response with `Idempotent-Replayed: true` and does nothing again. - A refused write (4xx) has no effect and releases its key: once you fix the cause, retry with the same key and the write runs. - A failed write (5xx) may have taken effect, so it is never run again under its key: a retry gets 409 `idempotency_outcome_unknown`. Check whether it took effect before retrying with a new key. - A retry while the first request is still running gets 409 `idempotency_request_in_progress`. A request still running after 5 minutes is treated as failed: a retry gets 409 `idempotency_outcome_unknown`. - The same key with a different request (method, path, query or body) gets 409 `idempotency_key_reused`. A write without the header gets 400 `idempotency_key_required`. Every response carries `X-Request-Id`. Errors share one shape, `{code, message, requestId, details?}`. Money is integer cents plus a currency code and dates are ISO-8601.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1
|
|
7
|
+
Contact: support@growwer.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.24.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'spec_helper'
|
|
14
|
+
require 'json'
|
|
15
|
+
|
|
16
|
+
# Unit tests for Growwer::FilesApi
|
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
|
18
|
+
# Please update as you see appropriate
|
|
19
|
+
describe 'FilesApi' do
|
|
20
|
+
before do
|
|
21
|
+
# run before each test
|
|
22
|
+
@api_instance = Growwer::FilesApi.new
|
|
23
|
+
end
|
|
24
|
+
|
|
25
|
+
after do
|
|
26
|
+
# run after each test
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
describe 'test an instance of FilesApi' do
|
|
30
|
+
it 'should create an instance of FilesApi' do
|
|
31
|
+
expect(@api_instance).to be_instance_of(Growwer::FilesApi)
|
|
32
|
+
end
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
# unit tests for upload_file
|
|
36
|
+
# Upload a file
|
|
37
|
+
# Uploads a document (odt, doc, docx or txt, up to 8 MB) for a later write to reference by its `id`. A file belongs to you, can be used by one write, and expires 24 hours after it was uploaded; an expired or used file is answered like an unknown one.
|
|
38
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
39
|
+
# @param file
|
|
40
|
+
# @param [Hash] opts the optional parameters
|
|
41
|
+
# @return [UploadFile201Response]
|
|
42
|
+
describe 'upload_file test' do
|
|
43
|
+
it 'should work' do
|
|
44
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
45
|
+
end
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
end
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Growwer API
|
|
3
|
+
|
|
4
|
+
#The Growwer customer API. Authenticate every call with an API key created on your profile page, sent as `Authorization: Bearer <key>`. A read key can call every GET operation; writes need a read and write key and an `Idempotency-Key` header. Idempotency: use a new `Idempotency-Key` (1 to 255 printable ASCII characters) for each operation and reuse it only to retry that same operation. Keys belong to your account, not to one API key. - A successful write is stored for 30 days: a retry with the same key and the same request replays its response with `Idempotent-Replayed: true` and does nothing again. - A refused write (4xx) has no effect and releases its key: once you fix the cause, retry with the same key and the write runs. - A failed write (5xx) may have taken effect, so it is never run again under its key: a retry gets 409 `idempotency_outcome_unknown`. Check whether it took effect before retrying with a new key. - A retry while the first request is still running gets 409 `idempotency_request_in_progress`. A request still running after 5 minutes is treated as failed: a retry gets 409 `idempotency_outcome_unknown`. - The same key with a different request (method, path, query or body) gets 409 `idempotency_key_reused`. A write without the header gets 400 `idempotency_key_required`. Every response carries `X-Request-Id`. Errors share one shape, `{code, message, requestId, details?}`. Money is integer cents plus a currency code and dates are ISO-8601.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1
|
|
7
|
+
Contact: support@growwer.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.24.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'spec_helper'
|
|
14
|
+
require 'json'
|
|
15
|
+
|
|
16
|
+
# Unit tests for Growwer::ManagedServicesApi
|
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
|
18
|
+
# Please update as you see appropriate
|
|
19
|
+
describe 'ManagedServicesApi' do
|
|
20
|
+
before do
|
|
21
|
+
# run before each test
|
|
22
|
+
@api_instance = Growwer::ManagedServicesApi.new
|
|
23
|
+
end
|
|
24
|
+
|
|
25
|
+
after do
|
|
26
|
+
# run after each test
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
describe 'test an instance of ManagedServicesApi' do
|
|
30
|
+
it 'should create an instance of ManagedServicesApi' do
|
|
31
|
+
expect(@api_instance).to be_instance_of(Growwer::ManagedServicesApi)
|
|
32
|
+
end
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
# unit tests for estimate_managed_service_proposals
|
|
36
|
+
# Estimate accepting proposals
|
|
37
|
+
# Totals the campaign's accepted proposals that still await their order and the `proposed` ones you name in `accept`, and compares the total with your wallet's available balance. Each proposal counts at its `currentPrice`, or at its `proposedPrice` when the media no longer offers the service. Nothing is accepted, charged or reserved, so a read-only key may call it and it takes no Idempotency-Key. The estimate is advisory: accepting a proposal charges nothing. The team charges your wallet when it places the order for an accepted proposal, and the same balance pays for the orders you place yourself.
|
|
38
|
+
# @param id
|
|
39
|
+
# @param [Hash] opts the optional parameters
|
|
40
|
+
# @option opts [ManagedServiceProposalsEstimateRequest] :managed_service_proposals_estimate_request
|
|
41
|
+
# @return [ManagedServiceProposalsEstimate]
|
|
42
|
+
describe 'estimate_managed_service_proposals test' do
|
|
43
|
+
it 'should work' do
|
|
44
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
45
|
+
end
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# unit tests for get_managed_service_campaign
|
|
49
|
+
# Get a managed service campaign
|
|
50
|
+
# @param id
|
|
51
|
+
# @param [Hash] opts the optional parameters
|
|
52
|
+
# @return [ManagedServiceCampaign]
|
|
53
|
+
describe 'get_managed_service_campaign test' do
|
|
54
|
+
it 'should work' do
|
|
55
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
56
|
+
end
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
# unit tests for get_managed_service_proposals_summary
|
|
60
|
+
# Download the summary of a campaign's proposals
|
|
61
|
+
# The PDF the campaign page offers: the proposals awaiting your review, accepted or being published, newest first, in your language. With `extended=true` it also shows each proposal's price, the price it was proposed at (`proposedPrice`).
|
|
62
|
+
# @param id
|
|
63
|
+
# @param [Hash] opts the optional parameters
|
|
64
|
+
# @option opts [String] :extended Whether to show the prices.
|
|
65
|
+
# @return [File]
|
|
66
|
+
describe 'get_managed_service_proposals_summary test' do
|
|
67
|
+
it 'should work' do
|
|
68
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
69
|
+
end
|
|
70
|
+
end
|
|
71
|
+
|
|
72
|
+
# unit tests for list_managed_service_campaigns
|
|
73
|
+
# List your managed service campaigns
|
|
74
|
+
# The campaigns your managed service runs for you, newest first. Without a managed service the list is empty: GET /me says whether you have one.
|
|
75
|
+
# @param [Hash] opts the optional parameters
|
|
76
|
+
# @option opts [Integer] :limit Campaigns per page, 1 to 100.
|
|
77
|
+
# @option opts [Integer] :offset Campaigns to skip.
|
|
78
|
+
# @return [ListManagedServiceCampaigns200Response]
|
|
79
|
+
describe 'list_managed_service_campaigns test' do
|
|
80
|
+
it 'should work' do
|
|
81
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
82
|
+
end
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
# unit tests for list_managed_service_proposals
|
|
86
|
+
# List the proposals of a campaign
|
|
87
|
+
# The medias the team proposes for the campaign, newest first. Those `proposed` await your review (POST /managed-service/campaigns/{id}/proposals/review).
|
|
88
|
+
# @param id
|
|
89
|
+
# @param [Hash] opts the optional parameters
|
|
90
|
+
# @option opts [String] :state Only proposals in these states, comma-separated: `proposed`, `accepted`, `cancelled`, `purchase_started`, `purchase_finished`.
|
|
91
|
+
# @option opts [Integer] :limit Proposals per page, 1 to 100.
|
|
92
|
+
# @option opts [Integer] :offset Proposals to skip.
|
|
93
|
+
# @return [ListManagedServiceProposals200Response]
|
|
94
|
+
describe 'list_managed_service_proposals test' do
|
|
95
|
+
it 'should work' do
|
|
96
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
97
|
+
end
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
# unit tests for request_managed_service_campaign
|
|
101
|
+
# Request a new campaign
|
|
102
|
+
# Asks your account manager for a new campaign, as the managed service page does: the team emails you to agree on it. For accounts with a managed service (GET /me `managedService.active`); without one, POST /managed-service/info-requests asks about the service. You may send 5 such requests per UTC day through the API. Past them it answers 429 `managed_service_request_limit_reached`, with `Retry-After` the time to the next UTC midnight. A request that is refused (4xx) does not count; one that fails on the server (5xx) does, as it may have been sent.
|
|
103
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
104
|
+
# @param managed_service_request
|
|
105
|
+
# @param [Hash] opts the optional parameters
|
|
106
|
+
# @return [ManagedServiceRequestSent]
|
|
107
|
+
describe 'request_managed_service_campaign test' do
|
|
108
|
+
it 'should work' do
|
|
109
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
110
|
+
end
|
|
111
|
+
end
|
|
112
|
+
|
|
113
|
+
# unit tests for request_managed_service_info
|
|
114
|
+
# Ask about the managed service
|
|
115
|
+
# Asks the team about the managed service for your website, as the managed service landing page does: the team contacts you. For accounts without a managed service (GET /me `managedService.active`); with one, POST /managed-service/campaign-requests requests a new campaign. You may send 5 such requests per UTC day through the API. Past them it answers 429 `managed_service_request_limit_reached`, with `Retry-After` the time to the next UTC midnight. A request that is refused (4xx) does not count; one that fails on the server (5xx) does, as it may have been sent.
|
|
116
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
117
|
+
# @param managed_service_request
|
|
118
|
+
# @param [Hash] opts the optional parameters
|
|
119
|
+
# @return [ManagedServiceRequestSent]
|
|
120
|
+
describe 'request_managed_service_info test' do
|
|
121
|
+
it 'should work' do
|
|
122
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
123
|
+
end
|
|
124
|
+
end
|
|
125
|
+
|
|
126
|
+
# unit tests for review_managed_service_proposals
|
|
127
|
+
# Accept or reject proposals
|
|
128
|
+
# Decides on every proposal of the campaign that awaits your review (`state` `proposed`), as the campaign page does: name each one once, with `accept` or `reject`, and a comment for the team to reject one. Their order in the body does not matter. Accepting charges nothing: the team places the orders for the accepted proposals and your wallet pays for them then. POST /managed-service/campaigns/{id}/proposals/estimate says what they would cost. When every proposal is accepted the campaign moves to `proposal_accepted`; when one is rejected the team is told and prepares others. A proposal someone else moved on the campaign page while the request ran is answered in the state it reached.
|
|
129
|
+
# @param id
|
|
130
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
131
|
+
# @param managed_service_proposal_review_request
|
|
132
|
+
# @param [Hash] opts the optional parameters
|
|
133
|
+
# @return [ManagedServiceProposalReview]
|
|
134
|
+
describe 'review_managed_service_proposals test' do
|
|
135
|
+
it 'should work' do
|
|
136
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
137
|
+
end
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
end
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Growwer API
|
|
3
|
+
|
|
4
|
+
#The Growwer customer API. Authenticate every call with an API key created on your profile page, sent as `Authorization: Bearer <key>`. A read key can call every GET operation; writes need a read and write key and an `Idempotency-Key` header. Idempotency: use a new `Idempotency-Key` (1 to 255 printable ASCII characters) for each operation and reuse it only to retry that same operation. Keys belong to your account, not to one API key. - A successful write is stored for 30 days: a retry with the same key and the same request replays its response with `Idempotent-Replayed: true` and does nothing again. - A refused write (4xx) has no effect and releases its key: once you fix the cause, retry with the same key and the write runs. - A failed write (5xx) may have taken effect, so it is never run again under its key: a retry gets 409 `idempotency_outcome_unknown`. Check whether it took effect before retrying with a new key. - A retry while the first request is still running gets 409 `idempotency_request_in_progress`. A request still running after 5 minutes is treated as failed: a retry gets 409 `idempotency_outcome_unknown`. - The same key with a different request (method, path, query or body) gets 409 `idempotency_key_reused`. A write without the header gets 400 `idempotency_key_required`. Every response carries `X-Request-Id`. Errors share one shape, `{code, message, requestId, details?}`. Money is integer cents plus a currency code and dates are ISO-8601.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1
|
|
7
|
+
Contact: support@growwer.com
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.24.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'spec_helper'
|
|
14
|
+
require 'json'
|
|
15
|
+
|
|
16
|
+
# Unit tests for Growwer::OrdersApi
|
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
|
18
|
+
# Please update as you see appropriate
|
|
19
|
+
describe 'OrdersApi' do
|
|
20
|
+
before do
|
|
21
|
+
# run before each test
|
|
22
|
+
@api_instance = Growwer::OrdersApi.new
|
|
23
|
+
end
|
|
24
|
+
|
|
25
|
+
after do
|
|
26
|
+
# run after each test
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
describe 'test an instance of OrdersApi' do
|
|
30
|
+
it 'should create an instance of OrdersApi' do
|
|
31
|
+
expect(@api_instance).to be_instance_of(Growwer::OrdersApi)
|
|
32
|
+
end
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
# unit tests for approve_order
|
|
36
|
+
# Approve an order's delivery
|
|
37
|
+
# 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.
|
|
38
|
+
# @param id
|
|
39
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
40
|
+
# @param [Hash] opts the optional parameters
|
|
41
|
+
# @return [Order]
|
|
42
|
+
describe 'approve_order test' do
|
|
43
|
+
it 'should work' do
|
|
44
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
45
|
+
end
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# unit tests for approve_order_draft
|
|
49
|
+
# Approve a draft
|
|
50
|
+
# 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.
|
|
51
|
+
# @param id
|
|
52
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
53
|
+
# @param [Hash] opts the optional parameters
|
|
54
|
+
# @return [Order]
|
|
55
|
+
describe 'approve_order_draft test' do
|
|
56
|
+
it 'should work' do
|
|
57
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
58
|
+
end
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
# unit tests for cancel_order
|
|
62
|
+
# Cancel an order
|
|
63
|
+
# 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.
|
|
64
|
+
# @param id
|
|
65
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
66
|
+
# @param order_action_reason
|
|
67
|
+
# @param [Hash] opts the optional parameters
|
|
68
|
+
# @return [Order]
|
|
69
|
+
describe 'cancel_order test' do
|
|
70
|
+
it 'should work' do
|
|
71
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
72
|
+
end
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
# unit tests for create_order
|
|
76
|
+
# Place an order
|
|
77
|
+
# 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.
|
|
78
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
79
|
+
# @param order_create_request
|
|
80
|
+
# @param [Hash] opts the optional parameters
|
|
81
|
+
# @return [Order]
|
|
82
|
+
describe 'create_order test' do
|
|
83
|
+
it 'should work' do
|
|
84
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
85
|
+
end
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
# unit tests for download_order_briefing
|
|
89
|
+
# Download the draft you attached to an order
|
|
90
|
+
# 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.
|
|
91
|
+
# @param id
|
|
92
|
+
# @param [Hash] opts the optional parameters
|
|
93
|
+
# @return [File]
|
|
94
|
+
describe 'download_order_briefing test' do
|
|
95
|
+
it 'should work' do
|
|
96
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
97
|
+
end
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
# unit tests for download_order_draft
|
|
101
|
+
# Download the draft of an order
|
|
102
|
+
# 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.
|
|
103
|
+
# @param id
|
|
104
|
+
# @param [Hash] opts the optional parameters
|
|
105
|
+
# @return [File]
|
|
106
|
+
describe 'download_order_draft test' do
|
|
107
|
+
it 'should work' do
|
|
108
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
109
|
+
end
|
|
110
|
+
end
|
|
111
|
+
|
|
112
|
+
# unit tests for estimate_order
|
|
113
|
+
# Estimate an order
|
|
114
|
+
# 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.
|
|
115
|
+
# @param order_estimate_request
|
|
116
|
+
# @param [Hash] opts the optional parameters
|
|
117
|
+
# @return [OrderEstimate]
|
|
118
|
+
describe 'estimate_order test' do
|
|
119
|
+
it 'should work' do
|
|
120
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
121
|
+
end
|
|
122
|
+
end
|
|
123
|
+
|
|
124
|
+
# unit tests for get_order
|
|
125
|
+
# Get an order
|
|
126
|
+
# One order you bought, with its briefing, its draft and its state history.
|
|
127
|
+
# @param id
|
|
128
|
+
# @param [Hash] opts the optional parameters
|
|
129
|
+
# @return [Order]
|
|
130
|
+
describe 'get_order test' do
|
|
131
|
+
it 'should work' do
|
|
132
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
133
|
+
end
|
|
134
|
+
end
|
|
135
|
+
|
|
136
|
+
# unit tests for list_orders
|
|
137
|
+
# List your orders
|
|
138
|
+
# 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.
|
|
139
|
+
# @param [Hash] opts the optional parameters
|
|
140
|
+
# @option opts [String] :project_id Only the orders of this project of yours.
|
|
141
|
+
# @option opts [String] :media_id Only the orders on this media.
|
|
142
|
+
# @option opts [String] :state Only the orders in one of these states, comma-separated. An unknown state is refused with 422 and the list of valid ones.
|
|
143
|
+
# @option opts [Time] :updated_since Only the orders whose `updatedAt` is at or after this instant, an ISO-8601 date-time with its offset (send `+` as `%2B`).
|
|
144
|
+
# @option opts [String] :sort `-createdAt`, newest first, or `updatedAt`, least recently changed first. Orders of the same instant come in id order.
|
|
145
|
+
# @option opts [Integer] :limit Orders per page, 1 to 100.
|
|
146
|
+
# @option opts [Integer] :offset Orders to skip.
|
|
147
|
+
# @return [ListOrders200Response]
|
|
148
|
+
describe 'list_orders test' do
|
|
149
|
+
it 'should work' do
|
|
150
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
151
|
+
end
|
|
152
|
+
end
|
|
153
|
+
|
|
154
|
+
# unit tests for request_order_draft_update
|
|
155
|
+
# Request changes to a draft
|
|
156
|
+
# 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.
|
|
157
|
+
# @param id
|
|
158
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
159
|
+
# @param order_action_reason
|
|
160
|
+
# @param [Hash] opts the optional parameters
|
|
161
|
+
# @return [Order]
|
|
162
|
+
describe 'request_order_draft_update test' do
|
|
163
|
+
it 'should work' do
|
|
164
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
165
|
+
end
|
|
166
|
+
end
|
|
167
|
+
|
|
168
|
+
# unit tests for request_order_update
|
|
169
|
+
# Request changes to a delivery
|
|
170
|
+
# 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.
|
|
171
|
+
# @param id
|
|
172
|
+
# @param idempotency_key A new key for each write, reused only to retry that same write. 1 to 255 printable ASCII characters.
|
|
173
|
+
# @param order_action_reason
|
|
174
|
+
# @param [Hash] opts the optional parameters
|
|
175
|
+
# @return [Order]
|
|
176
|
+
describe 'request_order_update test' do
|
|
177
|
+
it 'should work' do
|
|
178
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
179
|
+
end
|
|
180
|
+
end
|
|
181
|
+
|
|
182
|
+
end
|