25 Aug’17

D365 Finance and OperationsOData API – Exposing Data Entities in D3FOE (Part 1)


In this blog article, we will see how we can expose standard and custom data entities using OData Client code generator to OData API for CRUD operations.


  1. Install OData Client Code Generator v4
  2. Create new Project
  3. Execute the OData Client code.

1. Install OData Client Code Generator v4:

  • Open Visual Studio.
  • Go to Tools -> Extensions and Updates
  • Go to Online Fast Tab -> Visual Studio Gallery -> Type ‘OData V4 Client Code Generator’
  • Click Download.
  • In the VSIX Installer dialog box, Click Install.
  • After Installation, it will ask you to restart the Visual Studio. Click Restart now.

2. Create new Project:

  • Click on new Project.
  • Go to Visual C# -> Windows -> Select Console ApplicationNote: Client Code Generator can work with any project.
  • Enter details and click OK.

3. Execute the OData Client code:

  • In Solution Explorer, right click the solution. Go to Add -> New Item.
  • Select OData Client. Click Add.
  • You will see 2 files added in the solution. Open the file with .tt extension (Text Template). In the file, update the Metadata URI.

  • Save and execute the .tt file. You can see a .cs file generated under the .tt file.


This will generate a code that exposes all the Data Entities of D365 Operations. You can use this generated code for CRUD operations. In the next part, we will see how to use this generated code to read and write data in tables using exposed data entities.

Written by

Sohagani Shah

ERP Developer

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload the CAPTCHA.

Want to streamline your business processes?

  • This field is for validation purposes and should be left unchanged.

Recent Articles

  • Reading more then 10K records in D3FOE OData API

    11 July’ 2018

    Introduction: We all know Dynamics 365 Finance and Operations has limitation of 10K records to be fetched at a time usi...

    Read more
  • Paging in D365 Customer Engagement v9.0

    10 July’ 2018

    Introduction: The Xrm.retrieveMultipleRecords method is used to retrieve a collection of records in Dynamics 365 Custom...

    Read more
  • Set up Dynamics 365 connection in Microsoft Social Engagement

    10 July’ 2018

    Introduction: This blog explains how to Set up Dynamics 365 connection in Microsoft Social Engagement. Steps to be follo...

    Read more
  • Voice of the Customer failed to install

    10 July’ 2018

    Introduction: Many people face issues in installing Voice of Customer solution on v9 environment and trying repeatedly ...

    Read more
  • Scribe Insight AX as a Web Service Find Block issue

    10 July’ 2018

    Introduction: If we need to look up for any value from AX then we do it by using a Find Block in Scribe Insight Eg: Basi...

    Read more