[JTL-WAWI API] MandatoryApiScopes / OptionalApiScopes

kelvin.

Sehr aktives Mitglied
15. Februar 2023
168
65
Frankfurt
Hallo zusammen, ich bin gerade am Testen der Rest API und habe paar Fragen zu den Scopes.

Gibt es eine Auflistung von alle Scopes?
Gibt es ein Scope wie read.all für das Schreiben und Löschen?
Kann mir jemand erklären, wann ich OptionalApiScopes nutzen soll?
Gibt es derzeit eine Möglichkeit Scopes im Nachhinein einer Anwendung freizugeben?
 

juergenl

Aktives Mitglied
26. Februar 2020
11
3
Hallo,

die Scopes werden in der Dokumentation jeweils bei den endpoints aufgelistet. Welche Scopes man nutzt hängt letztlich davon ab was man mit der API bewerkstelligen will. Wenn ich zum Beispiel mit salesorders arbeiten möchte schaue ich welche der in der Dokumentation aufgelisteten Funktionen ich nutzen möchte. Dann schaue ich welche Scopes dort unter Authorizations aufgelistet sind. Dann muss ich auch noch entsprechende scopes für customer raussuchen, weil man ohne Kunden eigentlich auch nichts mit Aufträgen anfangen kann.

Die benötigten Scopes werden dann bei der App Registrierung angegeben. Wenn man später zusätzliche Scopes braucht, muss dieser Prozess der App Registrierung noch einmal durchlaufen werden um diese anzumelden.
 
  • Gefällt mir
Reaktionen: kelvin.

kelvin.

Sehr aktives Mitglied
15. Februar 2023
168
65
Frankfurt
Danke @juergenl für die Antwort. Das die Scopes in der Doku bei den Endpoints steht, habe ich auch gesehen.
Ich brauche für mein Projekt sozusagen alle Scopes, da ich alle Enpoints einmal testen möchte.

Falls jemand einmal alle Scopes rausgeschrieben hat oder ein Script um alle Scopes aus der Doku zu extrahieren hat, wäre ich sehr dankbar.

EDIT: Hat sich geklärt. Ich konnte alle Scopes aus der Datei swagger.json extrahieren.
 
Zuletzt bearbeitet:

no80

Sehr aktives Mitglied
28. Juni 2023
755
89
Danke @juergenl für die Antwort. Das die Scopes in der Doku bei den Endpoints steht, habe ich auch gesehen.
Ich brauche für mein Projekt sozusagen alle Scopes, da ich alle Enpoints einmal testen möchte.

Falls jemand einmal alle Scopes rausgeschrieben hat oder ein Script um alle Scopes aus der Doku zu extrahieren hat, wäre ich sehr dankbar.

EDIT: Hat sich geklärt. Ich konnte alle Scopes aus der Datei swagger.json extrahieren.
Du kannst die direkt in Postman importieren.
 

Mumuso

Mitglied
30. Januar 2025
9
2
'availability.queryavailabilities', 'all.read', 'cancellationreason.querycancellationreasons', 'all.read', 'category.querycategories', 'all.read', 'category.createcategory', 'category.getcategory', 'all.read', 'category.updatecategory', 'category.querycategorydescriptions', 'category.createcategorydescription', 'category.deletecategorydescription', 'category.updatecategorydescription', 'category.addcategoryitems', 'colorcode.querycolorcodes', 'all.read', 'company.querycompanies', 'all.read', 'condition.queryconditions', 'all.read', 'CustomerCategory.QueryCustomerCategories', 'all.read', 'CustomerCategory.createCustomerCategory', 'CustomerCategory.getCustomerCategory', 'all.read', 'CustomerCategory.deleteCustomerCatory', 'CustomerCategory.UpdateCusterCatory', CustomerGroup Ergroup ',' customergroup.getCustomerGroup ',' all.read ',' customergroup.deleteCustomerGroup ',' customergroup.updateCustomerGroup ',' customer.querycustomers ',' all.read ',' customer.createcustomer ',' customer.getcustomer ',' all.read 'customer.querycustomerbankaccounts', 'customer.createcustomerbankaccount', 'customer.getcustomerbankaccount', 'customer.deletecustomerbankaccount', 'customer.updatecustomerbankaccount', 'customer.querycustomercontacts', 'customer.createcustomercontact', 'customer.getcustomercontact', 'customer.deletecustomercontact', 'customer.updatecustomercontact', 'customer.querycustomercustomfieldvalues', 'customer.deletecustomercustomfield', 'customer.updatecustomercustomfield', 'customer.querycustomernotes', 'customer.createcustomernote', 'customer.getcustomernote', 'customer.deletecustomernote', 'customer.updatecustomernote', 'customer.triggercustomerworkflowevent', 'Customer.QueryCustomerCustomFields', 'customer.QueryCustomerworkflowevents', 'item.queryitem Emcustomerprice ',' item.deleteitemcustomerprice ',' item.updateitemcustomerprice ',' item.queryitemcustomfieldvalues ',' all.read ',' item.deleteatemcustomfield ',' item.updateemcustomfiel ’item.deleteitemdescription', 'item.updateitemdescription', 'item.queryitemimages', 'all.read', 'item.createitemimage', 'item.deleteitemimage', 'item.updateitemimage', 'item.queryitemproperties', 'all.read', 'item.createitemproperty', 'item.deleteitemporty', 'item.queryitemsaleschannelprice', 'all.read', 'item.createitemsaleschannelprice', 'item.deleteitemsaleschannelprice', 'item.updateitemsaleschannelprice', 'item.queryitemspecialprice', 'all.read', 'item.updateitemspecialprice', 'item.queryitemsuppliers', 'all.read', 'item.createitemsupplier', 'item.deleteitemsupplier', 'item.updateitemsupplier', 'item.queryitemvariations', 'all.read', 'item.createitemvariation', 'item.deleteitemvariation', 'item.updateitemvariation', 'item.queryitemvariationvalues', 'all.read', 'item.createitemvariationvalue', 'item.deleteitemvariationvalue', 'item.updateitemvariationvalue', 'item.triggeritemworkflowevent', 'item.queryitemcustomfields', 'all.read', 'item.queryitemimagedata', 'all.read', 'item.queryitemworkflowevents', 'all.read', 'manufacturer.querymanufacturers', 'all.read', 'onholdreason.queryonholdreasons', 'all.read', 'paymentmethod.querypaymentmethods', 'all.read', 'productgroup.queryproductgroups', 'all.read', 'property.queryproperties', 'all.read', 'property.createproperty', 'property.querypropertyvalues', 'all.read', 'property.createpropertyvalue', 'property.deletepropertyvalue', 'property.updatepropertyvalue', 'property.querypropertyvaluedescriptions', 'all.read', 'property.createpropertyvaluedescription', 'property.deletepropertyvaluedescription', 'property.updatepropertyvaluedescription', 'property.querypropertygroups', 'all.read', 'property.createpropertygroup', 'saleschannel.getsaleschannels', 'all.read', 'salesorder.querysalesorders', 'all.read', 'salesorder.createsalesorder', 'salesorder.getsalesorder', 'all.read', 'salesorder.updatesalesorder', 'salesorder.cancelsalesorder', 'salesorder.querysalesordercustomfieldvalues', 'all.read', 'salesorder.deletesalesordercustomfield', 'salesorder.updatesalesordercustomfield', 'salesorder.querysalesorderfiles', 'all.read', 'salesorder.createsalesorderfile', 'salesorder.querysalesorderfiledata', 'all.read', 'salesorder.deletesalesorderfile', 'salesorder.querysalesorderlineitems', 'all.read', 'salesorder.createsalesorderlineitem','salesorder.deletesalesorderlineitem', 'salesorder.updatesalesorderlineitem', 'salesorder.querysalesordernotes', 'all.read', 'salesorder.createsalesordernote', 'salesorder.deletesalesordernote', 'salesorder.updatesalesordernote', 'salesorder.triggersalesorderworkflowevent', 'salesorder.querysalesordercustomfields', 'all.read', 'salesorder.querysalesorderworkflowevents', 'all.read', 'shippingclass.queryshippingclasses', 'all.read', 'shippingmethod.queryshippingmethods', 'all.read', 'stock.querystocksperitem', 'all.read', 'stock.stockadjustment', 'stock.querystockchanges', 'all.read', 'stock.queryserialnumberperwarehouse', 'all.read', 'supplier.querysuppliers', 'all.read', 'taxclass.querytaxclasses', 'all.read', 'transactionstatus.querytransactionstatus', 'all.read', 'warehouse.querywarehouses', 'all.read', 'warehouse.querystoragelocations', 'all.read', 'warehouse.querystoragelocationtype', 'warehouse.querywarehousetypes', 'all.read', 'wms.querypicklist', 'all.read', 'wms.createpicklist', 'wms.querypicklistposition', 'all.read', 'wms.querypicklisttemplate', 'all.read'
 
  • Gefällt mir
Reaktionen: Morimus
1. Februar 2025
4
4
Danke @juergenl für die Antwort. Das die Scopes in der Doku bei den Endpoints steht, habe ich auch gesehen.
Ich brauche für mein Projekt sozusagen alle Scopes, da ich alle Enpoints einmal testen möchte.

Falls jemand einmal alle Scopes rausgeschrieben hat oder ein Script um alle Scopes aus der Doku zu extrahieren hat, wäre ich sehr dankbar.

EDIT: Hat sich geklärt. Ich konnte alle Scopes aus der Datei swagger.json extrahieren.
Super danke für die Idee.

Hier für alle:


[
"accountingdata.queryaccountingdata",
"all.read",
"availability.queryavailabilities",
"cancellationreason.querycancellationreasons",
"category.addcategoryitems",
"category.createcategory",
"category.createcategorydescription",
"category.deletecategorydescription",
"category.getcategory",
"category.querycategories",
"category.querycategorydescriptions",
"category.updatecategory",
"category.updatecategorydescription",
"colorcode.querycolorcodes",
"company.querycompanies",
"condition.queryconditions",
"customer.createcustomer",
"customer.createcustomerbankaccount",
"customer.createcustomercontact",
"customer.createcustomernote",
"customer.deletecustomer",
"customer.deletecustomerbankaccount",
"customer.deletecustomercontact",
"customer.deletecustomercustomfield",
"customer.deletecustomernote",
"customer.getcustomer",
"customer.getcustomerbankaccount",
"customer.getcustomercontact",
"customer.getcustomernote",
"customer.querycustomerbankaccounts",
"customer.querycustomercontacts",
"customer.querycustomercustomfields",
"customer.querycustomercustomfieldvalues",
"customer.querycustomernotes",
"customer.querycustomers",
"customer.querycustomerworkflowevents",
"customer.triggercustomerworkflowevent",
"customer.updatecustomer",
"customer.updatecustomerbankaccount",
"customer.updatecustomercontact",
"customer.updatecustomercustomfield",
"customer.updatecustomernote",
"customercategory.createcustomercategory",
"customercategory.deletecustomercategory",
"customercategory.getcustomercategory",
"customercategory.querycustomercategories",
"customercategory.updatecustomercategory",
"customergroup.createcustomergroup",
"customergroup.deletecustomergroup",
"customergroup.getcustomergroup",
"customergroup.querycustomergroups",
"customergroup.updatecustomergroup",
"deliverynote.getdeliverynote",
"deliverynote.querydeliverynotes",
"invoice.getinvoice",
"invoice.queryinvoicecancellationreasons",
"invoice.queryinvoicelineitems",
"invoice.queryinvoices",
"invoice.queryinvoiceworkflowevents",
"invoice.triggerinvoiceworkflowevent",
"item.assignchilditemtoparent",
"item.createitem",
"item.createitemcustomerprice",
"item.createitemdescription",
"item.createitemimage",
"item.createitemproperty",
"item.createitemsaleschannelprice",
"item.createitemsupplier",
"item.createitemvariation",
"item.createitemvariationvalue",
"item.deleteitemcustomerprice",
"item.deleteitemcustomfield",
"item.deleteitemdescription",
"item.deleteitemimage",
"item.deleteitemproperty",
"item.deleteitemsaleschannelprice",
"item.deleteitemsupplier",
"item.deleteitemvariation",
"item.deleteitemvariationvalue",
"item.getitem",
"item.queryitemcustomerprices",
"item.queryitemcustomfields",
"item.queryitemcustomfieldvalues",
"item.queryitemdescriptions",
"item.queryitemimagedata",
"item.queryitemimages",
"item.queryitemproperties",
"item.queryitems",
"item.queryitemsaleschannelprice",
"item.queryitemspecialprice",
"item.queryitemsuppliers",
"item.queryitemvariations",
"item.queryitemvariationvalues",
"item.queryitemworkflowevents",
"item.triggeritemworkflowevent",
"item.updateitem",
"item.updateitemcustomerprice",
"item.updateitemcustomfield",
"item.updateitemdescription",
"item.updateitemimage",
"item.updateitemsaleschannelprice",
"item.updateitemspecialprice",
"item.updateitemsupplier",
"item.updateitemvariation",
"item.updateitemvariationvalue",
"manufacturer.querymanufacturers",
"onholdreason.queryonholdreasons",
"paymentmethod.querypaymentmethods",
"productgroup.queryproductgroups",
"property.createproperty",
"property.createpropertygroup",
"property.createpropertyvalue",
"property.createpropertyvaluedescription",
"property.deletepropertyvalue",
"property.deletepropertyvaluedescription",
"property.queryproperties",
"property.querypropertygroups",
"property.querypropertyvaluedescriptions",
"property.querypropertyvalues",
"property.updatepropertyvalue",
"property.updatepropertyvaluedescription",
"refund.queryrefundcancellationreasons",
"return.getreturn",
"return.queryreturnlineitems",
"return.queryreturns",
"returnreason.queryreturnreasons",
"returnstate.queryreturnstates",
"saleschannel.getsaleschannels",
"salesorder.cancelsalesorder",
"salesorder.createsalesorder",
"salesorder.createsalesorderfile",
"salesorder.createsalesorderlineitem",
"salesorder.createsalesorderlineitemfile",
"salesorder.createsalesordernote",
"salesorder.deletesalesordercustomfield",
"salesorder.deletesalesorderfile",
"salesorder.deletesalesorderlineitem",
"salesorder.deletesalesorderlineitemfile",
"salesorder.deletesalesordernote",
"salesorder.getsalesorder",
"salesorder.querysalesordercancellationreasons",
"salesorder.querysalesordercustomfields",
"salesorder.querysalesordercustomfieldvalues",
"salesorder.querysalesorderfiledata",
"salesorder.querysalesorderfiles",
"salesorder.querysalesorderlineitemfiledata",
"salesorder.querysalesorderlineitemfiles",
"salesorder.querysalesorderlineitems",
"salesorder.querysalesordernotes",
"salesorder.querysalesorders",
"salesorder.querysalesorderworkflowevents",
"salesorder.triggersalesorderworkflowevent",
"salesorder.updatesalesorder",
"salesorder.updatesalesordercustomfield",
"salesorder.updatesalesorderfile",
"salesorder.updatesalesorderlineitem",
"salesorder.updatesalesorderlineitemfile",
"salesorder.updatesalesordernote",
"shippingclass.queryshippingclasses",
"shippingmethod.queryshippingmethods",
"stock.queryserialnumberperwarehouse",
"stock.querystockchanges",
"stock.querystocksperitem",
"stock.stockadjustment",
"supplier.querysuppliers",
"taxclass.querytaxclasses",
"transactionstatus.querytransactionstatus",
"warehouse.querystoragelocations",
"warehouse.querystoragelocationtype",
"warehouse.querywarehouses",
"warehouse.querywarehousetypes",
"wms.createpicklist",
"wms.querypicklist",
"wms.querypicklistposition",
"wms.querypicklisttemplate"
]
 

Mumuso

Mitglied
30. Januar 2025
9
2
Eigentlich ist die API von JTL eine sehr unbequeme Sache, was das Abrufen von Daten betrifft. Was das Einpflegen angeht – dazu kann ich nichts sagen.


Ich empfehle, eigene API-Handler zu schreiben, so wird es flexibler und bequemer.
Python und FastAPI können dabei helfen.
 

Ähnliche Themen