I need to create a new Opportunity from the Dynamics CRM Partner Portal via a custom button. The company sells software with a server that holds license details from each customer. On the Customer page I have a link that links to a new page that shows the license details for the Customer (fetched from the License Server via REST). I now need to use this licence details and create a new Opportunity for the Customer via the Portal.
The above image is the OOB Customer entity form with an added link to view licence.
From the next image an Opportunity should be created with Opportunity Products as specified on the page. A01, A03 etc.
I am using MS Dynamics v8.2

Adding my 2 cents,
I think you cannot directly call Post calls as of now to CRM API.
Link stating same.
If you can tweak your process slightly a bit.
create a form or something and on save of record, fire workflow in crm which can be custom workflow and that custom workflow will take care of creating/updating opportunity with products.
Here is an article giving some Idea.