Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Development: Add Artemis icon and description to LTI's dynamic registration info #9222

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ public class Lti13ClientRegistration {
@JsonProperty("jwks_uri")
private String jwksUri;

@JsonProperty("logo_uri")
private String logoUri;

@JsonProperty("token_endpoint_auth_method")
private String tokenEndpointAuthMethod;

Expand Down Expand Up @@ -67,6 +70,7 @@ public Lti13ClientRegistration(String serverUrl, String clientRegistrationId) {
this.setRedirectUris(List.of(serverUrl + "/" + CustomLti13Configurer.LTI13_LOGIN_REDIRECT_PROXY_PATH));
this.setInitiateLoginUri(serverUrl + "/" + CustomLti13Configurer.LTI13_LOGIN_INITIATION_PATH + "/" + clientRegistrationId);
this.setJwksUri(serverUrl + "/.well-known/jwks.json");
this.setLogoUri(serverUrl + "/public/images/logo.png");

Lti13ToolConfiguration toolConfiguration = getLti13ToolConfiguration(serverUrl);
this.setLti13ToolConfiguration(toolConfiguration);
Expand All @@ -83,6 +87,7 @@ private static Lti13ToolConfiguration getLti13ToolConfiguration(String serverUrl
}
toolConfiguration.setDomain(domain);
toolConfiguration.setTargetLinkUri(serverUrl + "/courses");
toolConfiguration.setDescription("Artemis: Interactive Learning with Individual Feedback");
toolConfiguration.setClaims(Arrays.asList("iss", "email", "sub", "name", "given_name", "family_name"));
Message deepLinkingMessage = new Message(CustomLti13Configurer.LTI13_DEEPLINK_MESSAGE_REQUEST, serverUrl + "/" + CustomLti13Configurer.LTI13_DEEPLINK_REDIRECT_PATH);
toolConfiguration.setMessages(List.of(deepLinkingMessage));
Expand Down Expand Up @@ -145,6 +150,14 @@ public void setJwksUri(String jwksUri) {
this.jwksUri = jwksUri;
}

public String getLogoUri() {
return logoUri;
}

public void setLogoUri(String logoUri) {
this.logoUri = logoUri;
}

public String getTokenEndpointAuthMethod() {
return tokenEndpointAuthMethod;
}
Expand Down Expand Up @@ -179,6 +192,8 @@ public static class Lti13ToolConfiguration {
@JsonProperty("target_link_uri")
private String targetLinkUri;

private String description;

private List<Message> messages;

private List<String> claims;
Expand All @@ -199,6 +214,14 @@ public void setTargetLinkUri(String targetLinkUri) {
this.targetLinkUri = targetLinkUri;
}

public String getDescription() {
return description;
}

public void setDescription(String description) {
this.description = description;
}

public List<Message> getMessages() {
return messages;
}
Expand Down
Loading