allegro / allegro/allegro-api

[NEWS] Kampanie - umożliwiamy zarządzanie dedykowaną liczbą sztuk w kampanii / Campaigns – we enable management of a dedicated number of items in a campaign

Đang mở
#12,793 0 bình luận 0 reaction 1 người được giao Được @MaciejFrackowiak nhận Xem trên GitHub
News Offer - Badges and Promotion campaigns
Ngôn ngữ chính
Không có dữ liệu ngôn ngữ
Star
244
Fork
40
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

Kampanie to akcje promocyjne, które popularyzują oferty sprzedawcy, co przekłada się bezpośrednio na wzrost sprzedaży oraz większe zyski.

**Jak było dotychczas?**

Dla wybranych kampanii typu Black Week oraz Allegro Days [daliśmy sprzedawcom możliwość](https://developer.allegro.pl/news/kampanie-wprowadzimy-dedykowana-liczbe-sztuk-dla-wybranych-kampanii-blackweek-i-allegrodays-6MOMZRGr1SW) zarezerwowania określonej liczby sztuk, która dostępna będzie w sprzedaży w ramach takiej kampanii. Sprzedający mógł to zrobić jedynie w zakładce [Kampanie i programy](https://salescenter.allegro.com/campaigns) w Sales Center.

**Co zmieniliśmy?**

Udostępniliśmy dzisiaj możliwość zgłoszenia dedykowanej liczby sztuk produktu do wspomnianych wybranych kampanii przez publiczne API Allegro. W związku z tym:

* w [GET /sale/badge-campaigns](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/badgeCampaigns_get_all) dodaliśmy flagę “**stockReservationIsRequired**”, która informuje, czy kampania **wymaga** zadeklarowania przez sprzedającego dedykowanej liczby sztuk produktów przeznaczonych dla wybranej kampanii.

* w [POST /sale/badges](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/postBadges) dodaliśmy pole “**declaredStock.quantity**”, w którym sprzedający **musi** wskazać deklarowaną liczbę sztuk produktu przeznaczoną dla wybranej kampanii. Pole jest **wymagane wyłącznie** dla kampanii z flagą “**stockReservationIsRequired**” z wartością **true**.

Przykład:

* w przypadku flagi “**stockReservationIsRequired**” z wartością **true** pole “**declaredStock.quantity**” jest **wymagane**, jego brak **uniemożliwia** udział w kampanii;

* w przypadku flagi “**stockReservationIsRequired**” z wartością **false** pole “**declaredStock.quantity**” musi być **puste** (null), jego podanie **uniemożliwia** udział w kampanii.

* w odpowiedzi dla [POST /sale/badges](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/postBadges), [GET /sale/badges](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/getBadges), [GET /sale/badge-applications/{applicationId}](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/badgeApplications_get_one) i [GET /sale/badge-applications/{applicationId}](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/badgeApplications_get_one) dodaliśmy pole “**campaignStock.quantity**”, w którym zwracamy informację o zadeklarowanej, a następnie zarezerwowanej przez sprzedającego liczbie sztuk produktu dla wybranej kampanii.

Pierwsze kampanie z wymaganą deklaracją liczby sztuk przez publiczne API Allegro planujemy w ramach kampanii Allegro Days w lutym 2026.

**Dlaczego wprowadziliśmy zmianę?**

Chcemy, aby planowanie udziału ofert w kampaniach przez publiczne API Allegro było jeszcze prostsze. Dzięki wprowadzonym zmianom odłożymy zadeklarowaną liczbę sztuk na wirtualną półkę, która zapobiegnie wyprzedaniu się zapasu przed startem kampanii i zapewni ofercie udział w niej.

Więcej informacji o zarządzaniu kampaniami znajdziesz w [naszym poradniku](https://developer.allegro.pl/tutorials/jak-przypisac-oferte-kampanii-GRaj0q6Gwuy#jak-zglosic-oferte-do-kampanii-programow-specjalnych-i-oznaczen-allegro).

-----

Campaigns are promotional activities that popularize a seller's offers, which translates directly into increased sales and higher profits.

**How was it so far?**

For selected Black Week and Allegro Days campaigns, we have [given sellers the option](https://developer.allegro.pl/news/campaigns-we-will-introduce-a-dedicated-stock-for-selected-blackweek-and-allegrodays-campaigns-6MOMZRGr1SW) to reserve a specific number of items that will be available for sale as part of such campaigns. Sellers could only do this in the [Campaigns and Programs](https://salescenter.allegro.com/campaigns#tab0) tab in the Sales Center.

**What have we changed?**

Today, we have made it possible to submit a dedicated number of product units for the aforementioned selected campaigns via Allegro's public API. Therefore:

* in [GET /sale/badge-campaigns](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/badgeCampaigns_get_all), we have added the “**stockReservationIsRequired**” flag, which indicates whether the campaign **requires** the seller to declare a specific number of products for the selected campaign.

* in [POST /sale/badges](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/postBadges), we have added the “**declaredStock.quantity**” field, in which the seller must indicate the declared number of items for the selected campaign. The field is **required only** for campaigns with the “**stockReservationIsRequired**” flag set to **true**.

Example:

* if the “**stockReservationIsRequired**” flag is set to **true**, the “**declaredStock.quantity**” field is **required**; if it is missing, participation in the campaign is **not possible**;

* if the “**stockReservationIsRequired**” flag is set to **false**, the “**declaredStock.quantity**” field must be **empty** (null); if it is filled in, participation in the campaign will be **impossible**.

* in response to [POST /sale/badges](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/postBadges), [GET /sale/badges](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/getBadges), [GET /sale/badge-applications/{applicationId}](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/badgeApplications_get_one) and [GET /sale/badge-applications/{applicationId}](https://developer.allegro.pl/documentation/#tag/Badge-campaigns/operation/badgeApplications_get_one), we have added the “**campaignStock.quantity**” field, in which we return information about the number of product units declared and then reserved by the seller for the selected campaign.

We are planning the first campaigns requiring a declaration of the number of items via Allegro's public API as part of the Allegro Days campaign in February 2026.

**Why have we made this change?**

We want to make it even easier to plan your participation in campaigns via Allegro's public API. Thanks to the changes we have introduced, we will put the declared number of items on a virtual shelf, which will prevent the stock from selling out before the start of the campaign and ensure that your offer participates in it.

You can find more information on campaign management in [our tutorial](https://developer.allegro.pl/tutorials/how-to-submit-offers-to-campaigns-AgGjd6EmyH4#submitting-offers-to-campaigns-special-programs-and-allegro-badges).

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.