feat: add WB_SECRET_TOKEN to headers for marketplace API requests

This commit is contained in:
2025-10-13 20:23:14 +03:00
parent bd83f654c5
commit c9e07b8368
2 changed files with 7 additions and 3 deletions

View File

@@ -2,7 +2,7 @@ import time
from enum import StrEnum
from typing import AsyncIterator
from backend.config import WB_SECRET_TOKEN
from external.marketplace.base.core import BaseMarketplaceApi
from models import Marketplace
@@ -33,7 +33,11 @@ class WildberriesMarketplaceApi(BaseMarketplaceApi):
"Please check the marketplace credentials."
)
self.token = token
self.headers = {'Authorization': token, 'User-Agent': 'wbas_seller.denco.store3547'}
self.headers = {
'Authorization': token,
'User-Agent': 'wbas_seller.denco.store3547',
'X-Client-Secret': WB_SECRET_TOKEN
}
self.marketplace = marketplace
@property