Notifications
Announcements
No record found.
Hi,
Do we have possibility to import data from MySQL DB into Dynamics 365 -> Leads using a PHP script
We are capturing enquiries using 'form submission feature' available in our web application. These data will be stored in our MySQL DB in our online server. We are trying to import them.
Thank you
Thank you for your query.
There are multiple solutions:
Example:
https://powerobjects.com/flow/using-flow-to-create-dynamics-records-using-a-scheduled-flow/
https://docs.microsoft.com/en-us/powerapps/developer/data-platform/webapi/create-entity-web-api
https://github.com/AlexaCRM/php-crm-toolkit
https://www.kingswaysoft.com/products/ssis-integration-toolkit-for-microsoft-dynamics-365
https://docs.microsoft.com/en-us/power-platform/admin/import-data-all-record-types
If you have licenses and data volume is not too high, I would suggest using PowerAutomate (no-code solution).
Thanks for your support. We will check PowerAutomate solution as you suggested.
We understand that after set ting up the PowerAutomate solution we will still have the possibility to do manual entry also. Please confirm.
I have one more query. Could you please suggest.
Whether pricing involved in PowerAutomate solution as in this link flow.microsoft.com/.../
https://docs.microsoft.com/en-us/dynamics365/customerengagement/on-premises/basics/import-accounts-leads-other-data
https://docs.microsoft.com/en-us/power-platform/admin/api-request-limits-allocations
Thanks for your support.
We have decided to use WebAPI to create leads using a web application
We tried the PHP script as in https://stackoverflow.com/questions/41215067/trying-to-create-lead-in-dynamics-crm-using-api-in-php. We hosted this in our web application https://www.efacility.in/webapi-php-crm.php.
But we are getting the status code as '401'
Could you please suggest.
Thanks
Seems like the either WebAPI URL is not correct or your are using wrong entity name.
You can get the correct WebAPI URL using following steps:
Please note, you need to provide correct version as well.
Furthermore, you can download the OData Metadata to get the correct dataset name.
Pleas note, normally, dataset names are in plural, for example contact is accessed using contacts:
https://<your-org>.api.crm4.dynamics.com/api/data/v9.2/contacts
I would also recommend you to look at following libraries for PHP to make things easier:
https://github.com/AlexaCRM/dynamics-webapi-toolkit
https://github.com/saintsystems/dynamics-sdk-php
Also, you can first use Postman to test your calls, to setup a Postman Environment with D365, see following:
https://docs.microsoft.com/en-us/dynamics365/customerengagement/on-premises/developer/webapi/setup-postman-environment
We tried postman calls as you suggested. We tried as in this link https://dynamics-chronicles.com/article/tutorial-how-connect-step-step-d365-postman.
We registered a new dynamics 365 App but while creating ‘Environment’ got alert as 'You do not have permission to perform this action' . Please refer this doc for the screen shots
Please suggest is this related to my account in https://sierratec.crm5.dynamics.com/
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.
As AI tools become more common, we’re introducing a Responsible AI Use…
We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
Martin Dráb 49 Most Valuable Professional
André Arnaud de Cal... 38 Super User 2025 Season 2
#ManoVerse 31