#LOCAL("Scope", "") #WITH_ERROR(#FormError)
#IF(#FormError)

{InputError}

{PleaseCorrectErrors}

#ENDIF #IF(#TestAuthorizationResult) #IF(#DeveloperApp.token NE "")

{AuthPassHeader}

{AuthPassMessage}

#ELSE

{AuthFailHeader}

{AuthFailMessage}

#ENDIF #ENDIF #IF(NOT(#DeveloperApp))
#IF(#FeaturedActionAvailable(#Shop.Object, #UNDEF, "DeveloperApps") EQ "Allowed") #ENDIF
{AppName}*
{CallbackUrl}
{V2DeveloperCreateText02}
{AppScopes}* products_read
products_write
products_read_batch
orders_read
orders_write
customers_read
customers_write
legal_read
legal_write
carts_read
carts_write
newsletters_read
newsletters_write
scripttags_read
scripttags_write
#ELSE #IF (#DEFINED(#Shop.RESTAPIURL)) #ENDIF #IF(#FeaturedActionAvailable(#Shop.Object, #UNDEF, "DeveloperApps") EQ "Allowed") #IF(#DeveloperApp) #ENDIF #ENDIF
{AppName} #DeveloperApp.name
{RESTAPIURL} #Shop.RESTAPIURL
{AccessToken} #DeveloperApp.token
{AppScopes} #LOOP(#FROMPLAINLOOP(#DeveloperApp.scopes)) #Element
#IF(#Element EQ "products_read") #SET("Scope",#Scope."products_read,") #ENDIF #IF(#Element EQ "products_read_batch") #SET("Scope",#Scope."products_read_batch,") #ENDIF #IF(#Element EQ "products_write") #SET("Scope",#Scope."products_write,") #ENDIF #IF(#Element EQ "carts_read") #SET("Scope",#Scope."carts_read,") #ENDIF #IF(#Element EQ "carts_write")#SET("Scope",#Scope."carts_write,") #ENDIF #IF(#Element EQ "orders_read") #SET("Scope",#Scope."orders_read,") #ENDIF #IF(#Element EQ "orders_write") #SET("Scope",#Scope."orders_write,") #ENDIF #IF(#Element EQ "customers_read") #SET("Scope",#Scope."customers_read,") #ENDIF #IF(#Element EQ "customers_write") #SET("Scope",#Scope."customers_write,") #ENDIF #IF(#Element EQ "legal_read") #SET("Scope",#Scope."legal_read,") #ENDIF #IF(#Element EQ "legal_write") #SET("Scope",#Scope."legal_write,") #ENDIF #IF(#Element EQ "newsletters_read") #SET("Scope",#Scope."newsletters_read,") #ENDIF #IF(#Element EQ "newsletters_write") #SET("Scope",#Scope."newsletters_write,") #ENDIF #IF(#Element EQ "scripttags_read") #SET("Scope",#Scope."scripttags_read,") #ENDIF #IF(#Element EQ "scripttags_write") #SET("Scope",#Scope."scripttags_write,") #ENDIF #ENDLOOP
{ClientId} #DeveloperApp.clientId
{ClientSecret} #DeveloperApp.clientSecret
{CallbackUrl} #IF(#DeveloperApp.callbackUrl)#DeveloperApp.callbackUrl#ENDIF

{V2DeveloperSubmitHeadline}

{V2DeveloperSubmitText00Head} {V2DeveloperSubmitText00APILink} {V2DeveloperSubmitText00Tail}

{V2DeveloperSubmitText01Head} {V2DeveloperSubmitText01AuthProcessLink} {V2DeveloperSubmitText01Tail}

{V2DeveloperSubmitText02}

{V2DeveloperSubmitText03}

{V2DeveloperSubmitText04}

{V2DeveloperSubmitText05}

{V2DeveloperSubmitText06}

{V2DeveloperSubmitText07}

#ENDIF #ENDWITH_ERROR #ENDLOCAL