Created
March 16, 2018 08:48
-
-
Save teror4uks/259552e7d85fcec4adba8d446545239c to your computer and use it in GitHub Desktop.
MoySklad
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
MS_STOCK_URL = 'https://online.moysklad.ru/exchange/rest/stock/json' | |
MOD_TRUE = 'showConsignments=true' | |
ALL_STOCK = 'stockMode=ALL_STOCK' | |
MS_USER = 'user' | |
MS_PASSWORD = 'pass' | |
with_mods = '{}?{}&{}'.format(MS_STOCK_URL, MOD_TRUE, ALL_STOCK) | |
r = requests.get(with_mods, auth=(MS_USER, MS_PASSWORD)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment