Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

To use the Canvas connector, add the <canvas.init> element in your configuration before carrying out any other Canvas operations. 

Canvas uses an access token for authorization. For more information on authentication, see https://canvas.instructure.com/doc/api/file.oauth.html.

Code Block
languagexml
titleinit
 <canvas.init>
    <apiUrl>{$url:apiUrl}</apiUrl>
	<accessToken>{$url:accessToken}</accessToken>
 </canvas.init>
Properties 
  • apiUrl: The API URL of Canvas.
  • accessToken: The generated access token.

Configuring the message formatters and builders

Ensure that the following Axis2 configurations are added and enabled in the <ESB_HOME>\repository\conf\axis2\axis2.xml file.

Required message formatter
Code Block
languagexml
<messageFormatter contentType="multipart/form-data" class="org.wso2.carbon.relay.ExpandingMessageFormatter"/>
Required message builder
Code Block
languagexml
<messageBuilder contentType="multipart/form-data" class="org.wso2.carbon.relay.BinaryRelayBuilder"/>

Ensure that the following Axis configurations are disabled (if already enabled) in the <ESB_HOME>\repository\conf\axis2\axis2.xml file.

Message formatter to disable
Code Block
languagexml
<messageFormatter contentType="multipart/form-data" class="org.apache.axis2.transport.http.MultipartFormDataFormatter"/>
Message builder to disable
Code Block
languagexml
<messageBuilder contentType="multipart/form-data" class="org.apache.axis2.builder.MultipartFormDataBuilder"/>

Configuring the operations

Now that you have connected to Canvas, use the information in the following topics to perform various operations with the connector. After you have completed your configurations, see Testing the Canvas Integration.

...