AX 2012: Create AIF custom service
Views (1579)
Purpose:
The purpose of this document is to illustrate how we can develop AIF custom service.
Business requirement:
Ability to integrate Dynamics AX with external systems.
Assumptions:
Application Integration Framework has been configured to process inbound and outbound messages.
Development:
- Create a data contract class.
- Use [DataContractAttribute(‘Name’)] attribute to indicate that the class represents data contract.
- Use [DataMemberAttribute(‘Name’)] attribute to indicate that the methods of class are data members.
- Use [AifCollectionTypeAttribute] attribute to define the types of return values and parameters.
- Create a service class.
- Set RunOn property of class to Server.
- Create a method decorated with [SysEntryPointAttribute(true)] attribute to indicate that this is a service operation.
- The boolean parameter of attribute defines whether AOSAuthorization property of tables will be checked or not in this method.
- Create a service contract by creating service node.
- Add service operation.
- Create a service group for the basic inbound port.
- Deploy the service group.
- The inbound port created must be activated now.

This was originally posted here.
*This post is locked for comments