The Moving Portal API documentationThe Moving Portal API documentation
Key concepts
API concepts
Services
Key concepts
API concepts
Services
  • Key concepts
  • API concepts
  • GDPR
  • Development
  • Releases
  • Services
  • Authentication
  • Instruction
  • Instruction search
  • Notes
  • Data
  • Referral
  • Quote
  • Quotes search
  • Supplier operations
  • Notifications
  • Testing
  • Email integration
  • Objects
  • Examples
    • Introducer
      • Authentication
      • Data
      • Quote
      • Quotes search
      • Referral
      • Instruction
      • Instructions search
      • Instruction notification
      • Notes
    • Supplier
      • Authentication
      • Data
      • Instruction
      • Instructions search
      • Instruction notification
      • Notes
      • Supplier operations
  • OTHER

Examples - Instruction service (Introducer) Introducer

Retrieve an instruction and update it's references

This example

  • Retrieves an instruction using the TMP Reference
  • Updates the introducer references
  • Retrieves an instruction using the Introducer Integration Reference and Introducer Customer Reference
Instruction service (Introducer)
@host=https://api.themovingportal.dev
@auth=BASICAUTHHEADER

@tmpReference=TMP123456
@introducerIntegrationReference=INTRODUCER-INT-REF-{{tmpReference}}
@introducerCustomerReference=INTRODUCER-CUST-REF-{{tmpReference}}

###
# name Get instruction
GET {{host}}/Instruction/{{tmpReference}}
Authorization: Basic {{auth}}

### Update references
PUT {{host}}/instruction/{{tmpReference}}/introducerreferences
Authorization: Basic {{auth}}
Content-Type: application/json

{
  "uniqueCustomerReference": "{{introducerCustomerReference}}",
  "uniqueIntegrationReference": "{{introducerIntegrationReference}}"
}

### Get instruction using integration reference
GET {{host}}/Instruction/introducer/{{introducerIntegrationReference}}
Authorization: Basic {{auth}}

### Get instruction using customer reference
GET {{host}}/Instruction/introducer/{{introducerCustomerReference}}
Authorization: Basic {{auth}}

Retrieve a file

This example retrieves a file (normally the finished report).

Instruction service (Introducer)
###
@host=https://api.themovingportal.dev
@auth=BASICAUTHHEADER

@tmpReference=TMP123456

GET {{host}}/Instruction/{{tmpReference}}/file/Report.pdf
Authorization: Basic {{auth}}

Typical code to retrieve the file might be:

C#
var httpClient = httpClientFactory.Create();
// Add headers for authentication
var url = "URL HERE";

using var response = await httpClient.GetAsync(url);
if (response.StatusCode == System.Net.HttpStatusCode.OK)
{
    var file = await response.Content.ReadAsByteArrayAsync();
    var savedFileNameName = "downloaded.pdf";
    File.WriteAllBytes(savedFileName, file);
}
else
{
    Console.WriteLine("Failed to retrieve file");
    Console.WriteLine($"Response Status Code {response.StatusCode}");
    var errors = await response.Content.ReadAsStringAsync();
    Console.WriteLine($"Errors: {errors}");
}
Last Updated: 11/4/25, 10:52 AM
Prev
Referral
Next
Instructions search