Skip to content

Quick start

dm-dk edited this page Sep 29, 2016 · 1 revision

API documentation (CHM format) and example app.config file are included in the package.

"Hello Connect" application, using the included communication provider implementation and configuration settings from app.config:

using System;
using AdobeConnectSDK;
using AdobeConnectSDK.Model;
 
 public class HelloAdobeConnect
 {
   static void Main(string[] args)
   {
       AdobeConnectXmlAPI api = new AdobeConnectXmlAPI();
       LoginStatus status = api.Login();
       string sessionKey = status.SessionInfo;
   }
 }

Security / credentials

Account using the API, should be an Administrator or Meeting Host group member. (reference: "Create Meeting" section of the Connect Web Services guide)

Testing

For testing purposes, the API can use custom implementation of ICommunicationProvider.

Example implementation of TestCommunicationProvider:

  using System;
  using AdobeConnectSDK.Interfaces;
  using AdobeConnectSDK.Model;

  internal class TestCommunicationProvider : ICommunicationProvider
  {
    public ISdkSettings Settings { get; set; }

    public ApiStatus ProcessRequest(string pAction, string qParams)
    {
      ApiStatus apiStatus = new ApiStatus();

      switch (pAction)
      {
        case "login":
          apiStatus = StatusCodes.NoAccess.
          apiStatus.SessionInfo = Guid.NewGuid().ToString();
          break;
   // .....

API extensions

Recommended way to extend the API is to use extension methods. This way new functionality can be grouped and separated from the core logic.

Conceptual test code for "GetAllMeetings", using extensions.

   using AdobeConnectSDK;
   using AdobeConnectSDK.Extensions;
   using AdobeConnectSDK.Model;

     [TestMethod]
     public void GetAllMeetings()
     {
       var result = this.Api.GetAllMeetings();
       Assert.IsTrue(result.Result.Any());
       Assert.AreEqual(7, result.Result.Count());
     }
Clone this wiki locally