Skip to main content

Reports API

API endpoints being removedThe /reports/api/invoices endpoints will be removed from the Mybring Reports application after 1. September 2023. New endpoint can be found in Invoice Archive with API endpoints /invoicearchive/api/invoices The replacement API is documented here
API changes after your company is converted to use new services

Bring is revising the service portfolio. Some of our services have been given new service names, service codes and pricing models.

If you are an existing user of Reports API, you will need to make some changes after your company is converted to use new services.

The Reports API can be used as a tool for analyzing your logistics with Bring. The API lets you generate reports within the categories status, quality and deviation, economy and environment. Supported report formats are XML and Excel.

Authentication

To integrate with the Bring APIs, you will need a Mybring user account with an API key. Information about prerequisites and authentication headers can be found on the general API Getting Started page.

Rate limiting

Clients exceeding multiple identical requests in a short time period will be throttled, and the response will contain HTTP status code 429.

Formats

REST XML/JSON over HTTP.

Fetching reports

The first two steps in the process is only necessary to find customer numbers and report types for the user. You can save these IDs, and perform the generation-step without verifying the IDs. The response may get added information, so implementation should ignore new elements added to the response.

  1. Get the customers IDs
  2. Get the list of report types available for the customer
  3. Initiate report creation and get the report ID. The Report ID is initially used to monitor reports creation progress, later to get the actual report (XML or Excel file).
  4. After initiating report creation, you can check the status, if it’s in-progress, completed or failed. When completed, a URL to the actual report is returned.
  5. Download report

Invoice sources

For specified invoice reports, three different report types can be returned depending on the invoice source:

Parcels

  • PARCEL_DOMESTIC
  • PARCEL_INTERNATIONAL

Cargo international or Oil express

  • AMPHORA_BCI
  • SYSPED
  • WINSPED_BCI

Cargo domestic, Sea or Home delivery

  • AMPHORA_DOMESTIC
  • AMPHORA_SEA
  • ALYSTRA

Endpoints

Base URL
                    https://www.mybring.com/reports/api
                
Usage Method Endpoint
List available customers GET /generate{mediaTypeExtension}
List available reports for a customer GET /generate/{customerId}{mediaTypeExtension}
Generate a report GET /generate/{customerId}/{reportTypeId}{mediaTypeExtension}
Check the status of a report GET /report/{reportId}/status{mediaTypeExtension}
Get report GET /report/{reportId}{mediaTypeExtension}
List invoice numbers GET /invoices/{customerOrGroupId}{mediaTypeExtension}

List available customers

get
                      https://www.mybring.com/reports/api/generate.json
https://www.mybring.com/reports/api/generate.xml

List available customers for the provided API credentials.

Request parameters

HTTP header Type Description
Accept-Language string Optional A comma-separated list of language codes, no for Norwegian, en for English, etc.

Responses

HTTP status code 200

Media type: application/json

The example below shows list of available customers

{
  "customers":[
    {
        "id":"PARCELS_NORWAY-00012341234",
        "name":"TEST CUSTOMER",
        "fullName":"TEST CUSTOMER (00012341234)",
        "reports":"https://www.mybring.com/reports/api/generate/PARCELS_NORWAY-00012341234/"
    }

]}

Media type: application/xml

The example below shows list of available customers

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<CustomerList>
    <customers>
        <id>PARCELS_NORWAY-00012341234</id>
        <name>TEST CUSTOMER</name>
        <reports>https://www.mybring.com/reports/api/generate/PARCELS_NORWAY-00012341234/</reports>
    </customers>
</CustomerList>

List available reports for a customer

get
                      https://www.mybring.com/reports/api/generate/{customerId}.json
https://www.mybring.com/reports/api/generate/{customerId}.xml

Each customer has a set of reports available. This endpoint lists all available reports for a given customer.

Request parameters

URI param Type Description
customerId string Required A customer ID from the ’list of available customers’ call.
HTTP header Type Description
Accept-Language string Optional A comma-separated list of language codes, no for Norwegian, en for English, etc.

Responses

HTTP status code 200

Media type: application/json

The example below shows list of available reports

{
  "reports": [
    {
      "id": "PARCELS-PRE_NOTIFICATION_RECEIVED",
      "name": "Pre-notification provided",
      "description": "Overview of shipments you have sent pre-notification for.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-PRE_NOTIFICATION_RECEIVED/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-RECEIVED_BY_BRING",
      "name": "Received by Bring",
      "description": "Overview of shipments received by Bring.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-RECEIVED_BY_BRING/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-PROBABLE_DELAYS",
      "name": "Probable delays",
      "description": "Overview of shipments that are likely to be delayed delivered to the recipient in accordance to Bring's guideline freight forwarding tables.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-PROBABLE_DELAYS/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-OUT_FOR_DELIVERY",
      "name": "Out for delivery to recipient today",
      "description": "Overview of shipments currently on vehicle for delivery.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-OUT_FOR_DELIVERY/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-NOT_COLLECTED_AT_PICKUPPOINT",
      "name": "Not collected at pick-up point",
      "description": "Overview of shipments at the pick-up point which have not yet been collected by the recipient.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-NOT_COLLECTED_AT_PICKUPPOINT/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-DELIVERY-ATTEMPTED",
      "name": "Delivery attempted",
      "description": "Overview of shipments for which delivery to the recipient has been attempted.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-DELIVERY-ATTEMPTED/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-MISSING_PRE_NOTIFICATION",
      "name": "Missing pre-notification",
      "description": "Overview of shipments received by Bring, but which are missing pre-notification. The shipments may be delayed.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-MISSING_PRE_NOTIFICATION/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-DELIVERED",
      "name": "Delivered to recipient",
      "description": "Overview of shipments which are delivered to the recipient.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-DELIVERED/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-RETURNED",
      "name": "Returned",
      "description": "Overview of shipments that have been returned to the sender.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-RETURNED/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-ADDRESS_QUALITY_B2B",
      "name": "Address quality for commercial parcels",
      "description": "Overview of commercial parcels with wrong post code in delivery address.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-ADDRESS_QUALITY_B2B/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-LAST_STATUS",
      "name": "Last status",
      "description": "Overview of last events Bring has for your shipments",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-LAST_STATUS/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-DELIVERY_QUALITY",
      "name": "Delivery quality",
      "description": "The report shows an overview of shipments that were not delivered in accordance with Bring's guideline freight forwarding tables.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-DELIVERY_QUALITY/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-FREIGHT_STATISTICS_SUMMED",
      "name": "Freight statistics, summarized",
      "description": "Overview of shipping costs per month per product",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-FREIGHT_STATISTICS_SUMMED/",
      "parameter": [
        {
          "name": "reporttype",
          "type": "string",
          "description": "INVOICED=Invoiced year, HANDED_IN=Handed in year"
        },
        {
          "name": "year",
          "type": "int",
          "description": "Year for report"
        }
      ]
    },
    {
      "id": "PARCELS-CURRENT_CALCULATED_SHIPPING",
      "name": "Current calculated shipping",
      "description": "Overview of current shipping costs for your sent parcels.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-CURRENT_CALCULATED_SHIPPING/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-FREIGHT_STATISTICS_DETAILED",
      "name": "Freight statistics, detailed",
      "description": "Overview of shipping costs per month per article.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-FREIGHT_STATISTICS_DETAILED/",
      "parameter": [
        {
          "name": "reporttype",
          "type": "string",
          "description": "INVOICED=Invoiced year, HANDED_IN=Handed in year"
        },
        {
          "name": "year",
          "type": "int",
          "description": "Year for report"
        }
      ]
    },
    {
      "id": "PARCELS-ECONOMY_AND_STATISTICS",
      "name": "Economy and statistics",
      "description": "Overview of shipping costs for your sent shipments.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-ECONOMY_AND_STATISTICS/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    },
    {
      "id": "PARCELS-SPECIFIED_INVOICE",
      "name": "Specified invoice",
      "description": "Overview of what is invoiced per shipment.",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-SPECIFIED_INVOICE/",
      "parameter": [
        {
          "name": "invoiceNumber",
          "type": "string",
          "description": "Invoice number for the report"
        }
      ]
    },
    {
      "id": "PARCELS-ADDITIONAL-COSTS",
      "name": "Statistics on extra delivery and delivery attempts",
      "description": "The report shows statistics and costs of additional delivery attempt by the recipient or by delivery location",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-ADDITIONAL-COSTS/",
      "parameter": [
        {
          "name": "invoiceNumber",
          "type": "string",
          "description": "Invoice number for the report"
        }
      ]
    },
    {
      "id": "PARCELS-ADDITIONAL-COSTS",
      "name": "Statistics on extra delivery and delivery attempts",
      "description": "The report shows statistics and costs of additional delivery attempt by the recipient or by delivery location",
      "url": "https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-ADDITIONAL-COSTS/",
      "parameter": [
        {
          "name": "fromDate",
          "type": "date",
          "description": "Startdate of the report. Format: DD.MM.YYYY"
        },
        {
          "name": "toDate",
          "type": "date",
          "description": "Enddate of the report. Format: DD.MM.YYYY"
        }
      ]
    }
  ]
}

Media type: application/xml

The example below shows list of available reports

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<ReportList>
    <reports>
        <id>PARCELS-PRE_NOTIFICATION_RECEIVED</id>
        <name>Pre-notification provided</name>
        <description>Overview of shipments you have sent pre-notification for.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-PRE_NOTIFICATION_RECEIVED/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-RECEIVED_BY_BRING</id>
        <name>Received by Bring</name>
        <description>Overview of shipments received by Bring.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-RECEIVED_BY_BRING/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-PROBABLE_DELAYS</id>
        <name>Probable delays</name>
        <description>Overview of shipments that are likely to be delayed delivered to the recipient in accordance to Bring's guideline freight forwarding tables.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-PROBABLE_DELAYS/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-OUT_FOR_DELIVERY</id>
        <name>Out for delivery to recipient today</name>
        <description>Overview of shipments currently on vehicle for delivery.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-OUT_FOR_DELIVERY/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-NOT_COLLECTED_AT_PICKUPPOINT</id>
        <name>Not collected at pick-up point</name>
        <description>Overview of shipments at the pick-up point which have not yet been collected by the recipient.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-NOT_COLLECTED_AT_PICKUPPOINT/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-DELIVERY-ATTEMPTED</id>
        <name>Delivery attempted</name>
        <description>Overview of shipments for which delivery to the recipient has been attempted.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-DELIVERY-ATTEMPTED/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-MISSING_PRE_NOTIFICATION</id>
        <name>Missing pre-notification</name>
        <description>Overview of shipments received by Bring, but which are missing pre-notification. The shipments may be delayed.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-MISSING_PRE_NOTIFICATION/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-DELIVERED</id>
        <name>Delivered to recipient</name>
        <description>Overview of shipments which are delivered to the recipient.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-DELIVERED/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-RETURNED</id>
        <name>Returned</name>
        <description>Overview of shipments that have been returned to the sender.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-RETURNED/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-ADDRESS_QUALITY_B2B</id>
        <name>Address quality for commercial parcels</name>
        <description>Overview of commercial parcels with wrong post code in delivery address.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-ADDRESS_QUALITY_B2B/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-LAST_STATUS</id>
        <name>Last status</name>
        <description>Overview of last events Bring has for your shipments</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-LAST_STATUS/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-DELIVERY_QUALITY</id>
        <name>Delivery quality</name>
        <description>The report shows an overview of shipments that were not delivered in accordance with Bring's guideline freight forwarding tables.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-DELIVERY_QUALITY/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-FREIGHT_STATISTICS_SUMMED</id>
        <name>Freight statistics, summarized</name>
        <description>Overview of shipping costs per month per product</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-FREIGHT_STATISTICS_SUMMED/</url>
        <parameters>
            <parameter>
                <name>reporttype</name>
                <type>string</type>
                <description>INVOICED=Invoiced year, HANDED_IN=Handed in year</description>
            </parameter>
            <parameter>
                <name>year</name>
                <type>int</type>
                <description>Year for report</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-CURRENT_CALCULATED_SHIPPING</id>
        <name>Current calculated shipping</name>
        <description>Overview of current shipping costs for your sent parcels.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-CURRENT_CALCULATED_SHIPPING/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-FREIGHT_STATISTICS_DETAILED</id>
        <name>Freight statistics, detailed</name>
        <description>Overview of shipping costs per month per article.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-FREIGHT_STATISTICS_DETAILED/</url>
        <parameters>
            <parameter>
                <name>reporttype</name>
                <type>string</type>
                <description>INVOICED=Invoiced year, HANDED_IN=Handed in year</description>
            </parameter>
            <parameter>
                <name>year</name>
                <type>int</type>
                <description>Year for report</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-ECONOMY_AND_STATISTICS</id>
        <name>Economy and statistics</name>
        <description>Overview of shipping costs for your sent shipments.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-ECONOMY_AND_STATISTICS/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-SPECIFIED_INVOICE</id>
        <name>Specified invoice</name>
        <description>Overview of what is invoiced per shipment.</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-SPECIFIED_INVOICE/</url>
        <parameters>
            <parameter>
                <name>invoiceNumber</name>
                <type>string</type>
                <description>Invoice number for the report</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-ADDITIONAL-COSTS</id>
        <name>Statistics on extra delivery and delivery attempts</name>
        <description>The report shows statistics and costs of additional delivery attempt by the recipient or by delivery location</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-ADDITIONAL-COSTS/</url>
        <parameters>
            <parameter>
                <name>invoiceNumber</name>
                <type>string</type>
                <description>Invoice number for the report</description>
            </parameter>
        </parameters>
    </reports>
    <reports>
        <id>PARCELS-ADDITIONAL-COSTS</id>
        <name>Statistics on extra delivery and delivery attempts</name>
        <description>The report shows statistics and costs of additional delivery attempt by the recipient or by delivery location</description>
        <url>https://api.bring.com.com/reports/api/generate/PARCELS_NORWAY-00012341234/PARCELS-ADDITIONAL-COSTS/</url>
        <parameters>
            <parameter>
                <name>fromDate</name>
                <type>date</type>
                <description>Startdate of the report. Format: DD.MM.YYYY</description>
            </parameter>
            <parameter>
                <name>toDate</name>
                <type>date</type>
                <description>Enddate of the report. Format: DD.MM.YYYY</description>
            </parameter>
        </parameters>
    </reports>
</ReportList>

Generate a report

get
                      https://www.mybring.com/reports/api/generate/{customerId}/{reportTypeId}.json
https://www.mybring.com/reports/api/generate/{customerId}/{reportTypeId}.xml

To generate a report do a GET to the supplied URL, and include the parameters described in the previous response. You need not invoke the two first steps for every report generation if customer id and report type are known.

This is asynchronous request. So the GET-call will return 202, telling the caller the that the request for a report is put on the queue. The URL to query to get the status for the request if provided as an HTTP header and also in the response.

The example below shows how to generate a PARCELS-DELIVERED report for PARCELS_NORWAY-00012341234 in the period 01.07.2014 to 01.08.2014.

Request parameters

URI param Type Description
customerId string Required A customer ID from the ’list of available customers’ call.
reportTypeId string Required A report type ID from the ’list of available reports’ call.
HTTP header Type Description
Accept-Language string Optional A comma-separated list of language codes, no for Norwegian, en for English, etc.
Query param Type Description
parameterName string Required The different report types have different params. The params are documented in the list of available reports, for example fromDate and toDate.

Responses

HTTP status code 202

Media type: application/json

The example below shows successful reports generation response with URL

{
  "statusUrl":"https://www.mybring.com/reports/api/report/db285042-6e8d-4563-94ca-eb1100706a73/status/"
}

Media type: application/xml

The example below shows successful reports generation response with URL

<result>
  <statusUrl>https://www.mybring.com/reports/api/report/db285042-6e8d-4563-94ca-eb1100706a73/status/</statusUrl>
</result>

Check the status of a report

get
                      https://www.mybring.com/reports/api/report/{reportId}/status.json
https://www.mybring.com/reports/api/report/{reportId}/status.xml

Since the generation of reports may take several minutes, we supply a status address to check the status of the report generation. The status page will display NOT_DONE, until the report is ready to be downloaded. When the report is ready, URLs to download the report will be in the response

Request parameters

URI param Type Description
reportId string Required A report ID from a ‘generate a report’ call.
HTTP header Type Description
Accept-Language string Optional A comma-separated list of language codes, no for Norwegian, en for English, etc.

Responses

HTTP status code 200

Examples show different statuses.

Media type: application/json

The example below shows reports status done

{
  "status":"DONE",
  "xmlUrl":"https://www.mybring.com/reports/api/report/db285042-6e8d-4563-94ca-eb1100706a73.xml",
  "xlsUrl":"https://www.mybring.com/reports/api/report/db285042-6e8d-4563-94ca-eb1100706a73.xls"
}

The example below shows reports generated status

{
  "status":"NOT_DONE"
}

The example below shows reports generation failed status

{
  "status":"FAILED"
}

Media type: application/xml

The example below shows reports status not done

<result>
  <status>DONE</status>
  <xmlUrl>https://www.mybring.com/reports/api/report/db285042-6e8d-4563-94ca-eb1100706a73.xml</xmlUrl>
  <xlsUrl>https://www.mybring.com/reports/api/report/db285042-6e8d-4563-94ca-eb1100706a73.xls</xlsUrl>
</result>

The example below shows reports generated status

<result>
  <status>NOT_DONE</status>
</result>

The example below shows reports generation failed status

<result>
  <status>FAILED</status>
</result>

Get report

get
                      https://www.mybring.com/reports/api/report/{reportId}.xlsx
https://www.mybring.com/reports/api/report/{reportId}.xml

Returns the generated report.

Request parameters

URI param Type Description
reportId string Required A report ID from a ‘generate a report’ call.
HTTP header Type Description
Accept-Language string Optional A comma-separated list of language codes, no for Norwegian, en for English, etc.
Query param Type Description
compress boolean Optional Get the XML report as a compressed ZIP archive.

Responses

HTTP status code 200

Examples show the MetaData included in successful(200) response for specified invoice report vs other reports.

The example below shows empty report with invoice details under metadata section of Report response

<Report xmlns="urn:bring.no/mybring/Report">
  <MetaData>
    <ReportName>Specified invoice - Groupage and partload</ReportName>
    <FinishedAt type="iso8601">2019-12-12T12:31:36.933+01:00</FinishedAt>
    <CustomerId>3444353</CustomerId>
    <CustomerName>TEST Customer</CustomerName>
    <InvoiceNumber>1220033899</InvoiceNumber>
    <NumberOfRows>204</NumberOfRows>
    <InvoiceSource>AMPHORA_DOMESTIC</InvoiceSource>
    <AttachmentCount>Number of attachment(s):1</AttachmentCount>
    <AttachmentUrl>Invoices in Mybring.https://www.mybring.com/invoicearchive/invoice/attachmentsRedirect/3444353/1220033899.html</AttachmentUrl>
  </MetaData>
  <Lines>
    <Line>
      <PICK_UP_POSTAL_CODE>5020</PICK_UP_POSTAL_CODE>
      <RECEIVER_NAME>TEST Customer</RECEIVER_NAME>
      <DELIVERY_POSTAL_CODE>3050</DELIVERY_POSTAL_CODE>
      <WAYBILL_NUMBER>70700611051925484</WAYBILL_NUMBER>
      <FREIGHT_PAYER>A</FREIGHT_PAYER>
      <ITEM_DESCRIPTION>Frakt</ITEM_DESCRIPTION>
      <DESCRIPTION>RETAIL ITEMS FOR SALE IN SK STORES</DESCRIPTION>
      <FREIGHT_CALC_WEIGHT>150.0</FREIGHT_CALC_WEIGHT>
      <TRX_DATE>25.04.2019</TRX_DATE>
      <NUMBER_OF_PACKAGES>1</NUMBER_OF_PACKAGES>
      <GrossPrice>1426.00</GrossPrice>
      <AMOUNT>271.00</AMOUNT>
    </Line>
  </Lines>
</Report>

The example below shows empty report without invoice details

<Report xmlns="urn:bring.no/mybring/Report">
  <MetaData>
    <ReportName>Delivered to recipient</ReportName>
    <FinishedAt type="iso8601">2015-10-19T15:17:07.077+02:00</FinishedAt>
    <CustomerId>00012341234</CustomerId>
    <CustomerName>TEST CUSTOMER</CustomerName>
    <Interval>
      <Start type="iso8601">2015-01-01T00:00:00.000+01:00</Start>
      <End type="iso8601">2015-10-19T23:59:59.000+02:00</End>
    </Interval>
    <NumberOfRows>0</NumberOfRows>
  </MetaData>
  <Lines>
  </Lines>
</Report>

List invoice numbers

get
                      https://www.mybring.com/reports/api/invoices/{customerOrGroupId}.json
https://www.mybring.com/reports/api/invoices/{customerOrGroupId}.xml

** This endpoint has been removed ** This endpoint has been removed and will no longer return any results. This endpoint documentation only remains to aid in migrating away from this endpoint. Use the Invoice API instead: Invoice API / List of all Invoices Gets the list of invoice numbers for a customer id or a customer group. By default it shows last 65 days of invoices, with the possibility to access 365 days data by providing from date and to date. This endpoint support Main Customer Number only.

Request parameters

URI param Type Description
customerOrGroupId string Required Id for customer or customer group. Customer group id should have the prefix GROUP_.
HTTP header Type Description
Accept-Language string Optional A comma-separated list of language codes, no for Norwegian, en for English, etc.
Query param Type Description
fromDate string Optional Start date for fetching invoices in format dd.mm.yyyy.
Example: 01.01.2019
toDate string Optional End date for fetching invoices in format dd.mm.yyyy.
Example: 30.06.2019

Responses

HTTP status code 200

Media type: application/json

The example below shows an list of invoices

{
  "customerId": "00012341234",
  "invoiceNumbers": [
    {
      "label": "702941479 (10/18/2015)",
      "id": "702941479",
      "year": 2015,
      "month": 10,
      "day": 18,
      "invoiceSource": "AMPHORA_DOMESTIC"
    },
    {
      "label": "702926498 (10/8/2015)",
      "id": "702926498",
      "year": 2015,
      "month": 10,
      "day": 8,
      "invoiceSource": "PARCEL_DOMESTIC"
    },
    {
      "label": "702916952 (10/1/2015)",
      "id": "702916952",
      "year": 2015,
      "month": 10,
      "day": 1,
      "invoiceSource": "PARCEL_DOMESTIC"
    }
  ]
}

Media type: application/xml

The example below shows an list of invoices

<Invoice>
  <customerId>00012341234</customerId>
  <invoiceNumbers>
    <label>702941479 (10/18/2015)</label>
    <id>702941479</id>
    <year>2015</year>
    <month>10</month>
    <day>18</day>
    <invoiceSource>AMPHORA_DOMESTIC</invoiceSource>
  </invoiceNumbers>
  <invoiceNumbers>
    <label>702926498 (10/8/2015)</label>
    <id>702926498</id>
    <year>2015</year>
    <month>10</month>
    <day>8</day>
    <invoiceSource>PARCEL_DOMESTIC</invoiceSource>
  </invoiceNumbers>
  <invoiceNumbers>
    <label>702916952 (10/1/2015)</label>
    <id>702916952</id>
    <year>2015</year>
    <month>10</month>
    <day>1</day>
    <invoiceSource>PARCEL_DOMESTIC</invoiceSource>
  </invoiceNumbers>
</Invoice>
comments powered by Disqus