Skip to content

Latest commit

 

History

History
53 lines (37 loc) · 3.36 KB

README.md

File metadata and controls

53 lines (37 loc) · 3.36 KB

Sample console connector

oAuth2 .NET Intermediary

Description

This is a code sample that provides a working example of using the Autodesk Data Exchange SDK without the UI component. The sample code contains examples of creating and updating as well as retrieving an exchange via a console and provides integration points for client-side integrations.

This is recommended for solutions that require integration with the Autodesk Data Exchange via a service or a custom UI.

For samples that use the built-in UI see https://github.com/autodesk-platform-services/aps-dataexchange-connector

Thumbnail

image

Setup

The Autodesk Data Exchange SDK is installed into this project as a package reference. All required packages are a part of packages.config and will be restored automatically on first build.

Prerequisites

  1. Register an app, and select the Data Management and the Data Exchange APIs. Note down the values of Client ID, Client Secret and Auth Callback. For more information on different types of apps, refer Application Types page.
  2. Verify that you have access to the Autodesk Construction Cloud (ACC).
  3. Visual Studio.
  4. Dot NET Framework 4.8 with basic knowledge of C#.

Running locally

  1. Clone this repository using git clone.
  2. Follow these instructions for installing the Data Exchange .Net SDK NuGet package in Visual Studio.[Note: Autodesk.DataExchange.UI is not required for console application.]
  3. Restore the Data Exchange SDK packages by one of the following approaches:
    • Building the solution using Visual Studio IDE, or

    • Building the solution using BuildSolution.bat [Note:Prior to executing "BuildSolution.bat," follow these steps

      Step-1 download and unzip nuget packages with appropriate versions to parent directory of repo.

      Step-2 either add the path of msbuild.exe (VS 2022) to the environment variables or utilize the developer command prompt ( for VS 2022 only).]

  4. Add values for Client Id, Client Secret and Auth callback in the App.config file in the sample console connector.

Once you build and run the sample console connector, it will open the URL for authentication in a web browser. You can enter your credentials in the authentication page and on successful authentication, you will see the Console connector screen as seen in the thumbnail above.

Further Reading

Documentation:

License

This sample code is part of the Autodesk Data Exchange .NET SDK (Software Development Kit) beta. It is subject to the license in Center Code covering the Autodesk Data Exchange .NET SDK (Software Development Kit) beta.

Written by

Dhiraj Lotake, Autodesk