Created
January 29, 2016 23:58
-
-
Save robertmassaioli/51560977faf2a056062e to your computer and use it in GitHub Desktop.
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
// Verify that the request for this Atlassian Connect Web Panel has | |
// a valid JWT token from the Host Product | |
@FilterWith(JwtFilter.class) | |
public Result sayHello(Context context) { | |
// Get the tenant out of the Context (the tenant is provided by the JwtFilter) | |
final Tenant tenant = (Tenant) context.getAttribute(JwtFilter.ATLASSIAN_CONNECT_TENANT_ATTR); | |
// Pass the tenant baseUrl into the freemarker template as the variable productBaseUrl | |
return Results.html().render("productBaseUrl", tenant.baseUrl); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment