Assume you will use this https://developer.cisco.com/meraki/api-v1/#!create-network-switch-link-aggregation to create an aggregate link.
From the documentation...
You need to issue this call for each aggregated link you want to create.
An aggregated link can have from 2 to 8 ports
The ports must each be specified in the call as serial number + port number, there is no option to specify a range.
To create ten links, you could create a 'for' loop to issue the ten calls, incrementing the port number each time, like...
ser1 = serialnumberofswitch1
ser2 = serialnumberof switch2
for port_num from 1 to 10
create_link(ser1, ser2, port_num)
...this is illustrative, not code in any particular language