Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Answered

D365BC Wave 2- Unable to Create & Publish Webservice using Xml Definition

(0) ShareShare
ReportReport
Posted on by 436

Hi All,

   I'm trying to create and publish webservice using Xml definition. After publishing the AL code , new web service not created, any one have idea why it is not created, do I need to change any setup or wrong in my code?

I'm using  D365BC wave 2, on premises. 

<?xml version="1.0" encoding="UTF-8"?>
<ExportedData>
    <TenantWebServiceCollection>
        <TenantWebService>
            <ObjectType>Page</ObjectType>
            <ServiceName>CustomersWS</ServiceName>
            <ObjectID>21</ObjectID>
            <Published>True</Published>
        </TenantWebService>
    </TenantWebServiceCollection>
</ExportedData>

  • Suggested answer
    Renato Fajdiga Profile Picture
    1,851 on at
    RE: D365BC Wave 2- Unable to Create & Publish Webservice using Xml Definition

    Small change for you, but big for BC.

    Glad that this resolved your issue :)

    Br,

    Renato

  • Marshal Profile Picture
    436 on at
    RE: D365BC Wave 2- Unable to Create & Publish Webservice using Xml Definition

    I used snippet twebservices, default value for <Published> is false, when I modified this parameter I mistakenly used True instead of true;

  • Suggested answer
    Olister Rumao Profile Picture
    3,959 on at
    RE: D365BC Wave 2- Unable to Create & Publish Webservice using Xml Definition

    Hi Marshal,

    I have tried this approach and it worked perfectly fine for me

    www.cloudfronts.com/.../

    I have not tried using webservices.xml but I think using twebservice snippet in VS Code should resolve the issue as you are probably missing something!

  • Mohamad Vajid Profile Picture
    on at
    RE: D365BC Wave 2- Unable to Create & Publish Webservice using Xml Definition

    I just tested as well with true instead of True and that is indeed the solution.

  • Marshal Profile Picture
    436 on at
    RE: D365BC Wave 2- Unable to Create & Publish Webservice using Xml Definition

    Thank you Renato,

    It is working now after changing to <Published>true</Published>  From  <Published>True</Published>.

  • Verified answer
    Renato Fajdiga Profile Picture
    1,851 on at
    RE: D365BC Wave 2- Unable to Create & Publish Webservice using Xml Definition

    Hi,

    have you tried to type "true" in published tag instead of "True"? Also, did you copy/paste this code to WebService.xml file or used snippet (twebservices)?

    I  am using this configuration and it works for me

    <?xml version="1.0" encoding="UTF-8"?>

    <ExportedData>

       <TenantWebServiceCollection>

           <TenantWebService>

               <ObjectType>Page</ObjectType>

               <ServiceName>serviceName</ServiceName>

               <ObjectID>objectId</ObjectID>

               <Published>true</Published>

           </TenantWebService>

       </TenantWebServiceCollection>

    </ExportedData>

    Best regards,

    Renato

  • Marshal Profile Picture
    436 on at
    RE: D365BC Wave 2- Unable to Create & Publish Webservice using Xml Definition

    Hi Thanks for your Response,

    I did not get any error when publishing ,  report, table, page extensions are working fine. launch file parameters also fine.

    Do I need to add any addition parameter in launch file to create webservice using xml definition ? below is my launch file setup

    pastedimage1575871767096v1.png

    Thanks 

    Marshal

  • Mohamad Vajid Profile Picture
    on at
    RE: D365BC Wave 2- Unable to Create & Publish Webservice using Xml Definition

    Hi,

    Do you get an error on publishing? Have you specified the correct server/instance in your launch.json file?

    Are you able to publish a page extension successfully?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Jainam Kothari – Community Spotlight

We are honored to recognize Jainam Kothari as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
Sohail Ahmed Profile Picture

Sohail Ahmed 1,452

#2
YUN ZHU Profile Picture

YUN ZHU 1,313 Super User 2025 Season 1

#3
Gerardo Rentería García Profile Picture

Gerardo Rentería Ga... 1,083 Most Valuable Professional

Featured topics

Product updates

Dynamics 365 release plans