Yes, there are APIs you can use. Go to Platform->Developer Toolkit and search for Onboarding to see them.
But there is another method to consider that doesn't require as much code development:
1) If DNA knows your smart account information, and you have new equipment being shipped, you should see those devices show up in your PnP inventory.
2) You can build a spreadsheet with all the necessary template variables filled out ahead of time.
3) You can pre-claim devices in inventory, and import the spreadsheet to populate the necessary variables, even if the actual equipment is still in boxes. Once the gear is plugged in and DNA detects it via PnP process, it will see the device has been claimed already and proceed with provisioning without your intervention.
That will get your basic onboarding config onto the device. You'd then need to automate only day-N provision to push the final production config.