How to create application and assign access profile to application through API

Hi Colin,
Following this thread - My organization is in the process of developing a programmatic workflow to create applications and applying access profiles via API

How do you recommend we proceed?