Introduction

Use these endpoints to request a service cancellation.

Request Lifecycle

Cancelling an active service and managing the cancellation request can be done as below:

  1. Create a service-cancellation-request resource by sending a POST request to /api/connect/services/service-cancellations/request with the body of the request containing the connect identifier of the service you would like to cancel and on which date you would like to cancel the service. The response’s http status will be 201 with a blank response body. There will be a Location response header with a URL. This URL is where the request outcome can be obtained.

  2. Make a GET request to the URL returned in 1. to retrieve the outcome of the request. While the request is in progress, the response’s http status will be 202. This means that the request has not finished yet, but will in a moment. If the request was successful a service-cancellation resource will be returned. If the request failed a 422 will be returned with the body containing details on why it failed in the standard error format.

Request Specifications

Table 1. API Versions
Version Header Changes

1 (Deprecated)

X-API-VERSION=1

Initial Version

2 (Deprecated)

X-API-VERSION=2

No change

3

X-API-VERSION=3

No change

4

X-API-VERSION=4

No change

5

X-API-VERSION=5

No change

6

X-API-VERSION=6

No Change

7

X-API-VERSION=7

No Change

API Version 1, 2, 3, 4, 5, 6 and 7

POST Request

Table 2. POST Request

Verb

POST

URI

/api/connect/services/service-cancellations/request

Table 3. POST HTTP Request Headers
Name Description

Authorization

The OAuth bearer access token

X-API-VERSION

The version of the endpoint you are accessing

Table 4. POST Request Body Fields
Path Type Description Required

serviceId

Number

The id of the service to be cancelled

Required

cancellationDate

String

The desired date service to be cancelled

Required

POST Response

Table 5. POST HTTP Status Codes
Status Code Meaning

201

The request was created successfully

401

Bearer token is missing or invalid

404

You do not have permission to perform this task

404

The id (of the service resource) provided does not exist

422

There are validation errors on the request you made. Check the response body to see what fields had issues

500

There was an unexpected error processing the request

Table 6. POST HTTP Response Headers
Name Description

Location

The URL from where the outcome of the request can be obtained. Poll this URL until the request is complete

GET Request

Note
The URI will be given to you in the Location header of the POST request.
Table 7. GET Request

Verb

GET

URI

/api/connect/services/service-cancellations/requests/{id}

Table 8. GET Request Path Variables

Path Variable

Purpose

id

The id of the service resource

Table 9. GET HTTP Request Headers
Name Description

Authorization

The OAuth bearer access token

X-API-VERSION

The version of the endpoint you are accessing

GET Response

Table 10. GET HTTP Status Codes
Status Code Meaning

200

The request is complete. The body contains the service-cancellation resource

202

The request is in progress

401

You are not authorized to make this request

400

The request was bad. Check the response body to see what the issue(s) are

404

You do not have permission to perform this task

404

The id (of the service resource) provided does not exist

422

The service-cancellation resource failed to be created. Check the response body to see why

422

The service-cancellation request IN_ERROR. Check the response body to see why

500

There was an unexpected error processing the request

Table 11. GET Response Body Fields
Path Type Description

serviceId

Number

The Connect identifier of the service-cancellation resource

cancelled

Boolean

The service cancelled or not

status

String

Status of the cancellation request

requestDate

String

The requested date for the service to be cancelled

requestedOn

String

The date/time, including UTC offset, when service cancellation request was made

requestedById

Number

The Connect identifier of the user requesting the service cancellation

requestedByName

String

The name of the user requesting the service cancellation

requestedByEmail

String

The email of the user requesting the service cancellation

errorDetail

Null

Error details. If any

cancelledOn

String

The date/time, including UTC offset, when nbn cancelled the service

abortedOn

Null

The date/time, including UTC offset, when user aborts the cancellation request

abortedById

Null

The Connect identifier of the user requesting the service cancellation request abort

abortedByName

Null

The name of the user requesting the service cancellation request abort

abortedByEmail

Null

The email of the user requesting the service cancellation request abort

canRequestCancellation

Boolean

The service is eligible for service cancellation

canAbortCancellation

Boolean

The service cancellation request is eligible for abort

canRescheduleCancellation

Boolean

The service cancellation request is eligible for reschedule

API Version 1, 2, 3, 4, 5, 6 and 7 - Examples

Successful Request

An service-cancellation-request resource is created by sending a POST request to /api/connect/services/service-cancellations/request.

POST Request
POST /api/connect/services/service-cancellations/request HTTP/1.1
Content-Type: application/json;charset=UTF-8
Authorization: Bearer **token**
X-API-VERSION: 7
Content-Length: 62
Host: 360-api.superloop.com

{
  "serviceId" : 12002,
  "cancellationDate" : "2025-05-26"
}

If all required fields were given, then the response to the request will have:

  1. a http status of 201

  2. a Location header with the URI of the service-cancellation resource.

Successful POST Response
HTTP/1.1 201 Created
Location: /api/connect/services/service-cancellations/requests/12002
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY

Once you have the URI from the Location header, poll that URI every so often by making a GET request. While cancelling the active service is in progress, the GET request’s response will have a http status of 202. Keep polling the URL until it finishes, once the request is completed successfully the GET request’s response will have a http status of 200 and the status will be COMPLETED.If the request is rejected by nbn the GET request’s response will have a http status of 200 and the status will be REJECTED.

Note
Please keep the polling to a sensible rate.
GET Request
GET /api/connect/services/service-cancellations/requests/12002 HTTP/1.1
Content-Type: application/json;charset=UTF-8
Authorization: Bearer **token**
X-API-VERSION: 7
Host: 360-api.superloop.com
Successful GET Response service cancellation requested
HTTP/1.1 200 OK
Content-Type: application/json
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Length: 515

{
  "serviceId" : 12002,
  "status" : "REQUESTED",
  "requestDate" : "2025-05-26",
  "requestedOn" : "2025-05-26T05:50:33Z",
  "requestedById" : 11001,
  "requestedByName" : "API User",
  "requestedByEmail" : "api@aaa-industries.com.au",
  "errorDetail" : null,
  "cancelledOn" : null,
  "abortedOn" : null,
  "abortedById" : null,
  "abortedByName" : null,
  "abortedByEmail" : null,
  "canRequestCancellation" : false,
  "canAbortCancellation" : true,
  "canRescheduleCancellation" : true,
  "cancelled" : false
}
Successful GET Response service cancellation in progress
HTTP/1.1 202 Accepted
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Successful GET Response service cancelled
HTTP/1.1 200 OK
Content-Type: application/json
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Length: 534

{
  "serviceId" : 12002,
  "status" : "COMPLETED",
  "requestDate" : "2025-05-26",
  "requestedOn" : "2025-05-26T05:50:33Z",
  "requestedById" : 11001,
  "requestedByName" : "API User",
  "requestedByEmail" : "api@aaa-industries.com.au",
  "errorDetail" : null,
  "cancelledOn" : "2025-05-26T05:50:33Z",
  "abortedOn" : null,
  "abortedById" : null,
  "abortedByName" : null,
  "abortedByEmail" : null,
  "canRequestCancellation" : false,
  "canAbortCancellation" : false,
  "canRescheduleCancellation" : false,
  "cancelled" : true
}
Successful GET Response service cancellation rejected
HTTP/1.1 200 OK
Content-Type: application/json
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Length: 516

{
  "serviceId" : 12002,
  "status" : "REJECTED",
  "requestDate" : "2025-05-26",
  "requestedOn" : "2025-05-26T05:50:27Z",
  "requestedById" : 11001,
  "requestedByName" : "API User",
  "requestedByEmail" : "api@aaa-industries.com.au",
  "errorDetail" : null,
  "cancelledOn" : null,
  "abortedOn" : null,
  "abortedById" : null,
  "abortedByName" : null,
  "abortedByEmail" : null,
  "canRequestCancellation" : false,
  "canAbortCancellation" : false,
  "canRescheduleCancellation" : false,
  "cancelled" : false
}

Invalid Request

If the request is invalid for any reason, a http status of 422 is returned and the body of the response will list the problems with the request.

Mandatory field not provided
POST Request
POST /api/connect/services/service-cancellations/request HTTP/1.1
Content-Type: application/json;charset=UTF-8
Authorization: Bearer **token**
X-API-VERSION: 7
Content-Length: 54
Host: 360-api.superloop.com

{
  "serviceId" : 12005,
  "cancellationDate" : null
}
POST Response with validation errors
HTTP/1.1 422 Unprocessable Entity
Content-Type: application/json
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Length: 442

{
  "httpStatusCode" : 422,
  "type" : "client.validation",
  "code" : "method.argument.not.valid",
  "message" : "Validation error",
  "apiSubErrors" : [ {
    "code" : "constraints.local.date.future.or.present",
    "message" : "must not be null or in the past",
    "object" : "connectRequestServiceCancellationCommand",
    "field" : "cancellationDate",
    "rejectedValue" : null
  } ],
  "timestamp" : "2025-05-26T05:50:39.751534027Z"
}
Service not active
POST Response with validation errors
HTTP/1.1 422 Unprocessable Entity
Content-Type: application/json
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Length: 596

{
  "httpStatusCode" : 422,
  "type" : "client.validation",
  "code" : "validation",
  "message" : "Validation error",
  "apiSubErrors" : [ {
    "code" : "constraints.service.not.eligible.for.cancellation",
    "message" : "The Service is not eligible for cancellation",
    "object" : "Service",
    "field" : "serviceId",
    "rejectedValue" : 12005
  }, {
    "code" : "constraints.service.not.active",
    "message" : "The Service is not in active state",
    "object" : "Service",
    "field" : "status",
    "rejectedValue" : false
  } ],
  "timestamp" : "2025-05-26T05:50:37.142508427Z"
}
Service has a cancellation already in progress
POST Response with validation errors
HTTP/1.1 422 Unprocessable Entity
Content-Type: application/json
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Length: 596

{
  "httpStatusCode" : 422,
  "type" : "client.validation",
  "code" : "validation",
  "message" : "Validation error",
  "apiSubErrors" : [ {
    "code" : "constraints.service.not.eligible.for.cancellation",
    "message" : "The Service is not eligible for cancellation",
    "object" : "Service",
    "field" : "serviceId",
    "rejectedValue" : 12005
  }, {
    "code" : "constraints.service.not.active",
    "message" : "The Service is not in active state",
    "object" : "Service",
    "field" : "status",
    "rejectedValue" : false
  } ],
  "timestamp" : "2025-05-26T05:50:25.165047918Z"
}
Service in an invalid state
POST Response with validation errors
HTTP/1.1 422 Unprocessable Entity
Content-Type: application/json
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Length: 624

{
  "httpStatusCode" : 422,
  "type" : "client.validation",
  "code" : "validation",
  "message" : "Validation error",
  "apiSubErrors" : [ {
    "code" : "constraints.service.not.eligible.for.cancellation",
    "message" : "The Service is not eligible for cancellation",
    "object" : "Service",
    "field" : "serviceId",
    "rejectedValue" : 12003
  }, {
    "code" : "constraints.service.not.eligible.for.cancellation",
    "message" : "The Service is not eligible for cancellation",
    "object" : "Service",
    "field" : "status",
    "rejectedValue" : true
  } ],
  "timestamp" : "2025-05-26T05:50:40.918668854Z"
}
Bad Request
GET Request bad request
GET /api/connect/services/service-cancellations/requests/AAA HTTP/1.1
Content-Type: application/json;charset=UTF-8
Authorization: Bearer **token**
X-API-VERSION: 7
Host: 360-api.superloop.com
GET Response bad request
HTTP/1.1 400 Bad Request
Content-Type: application/json
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Length: 363

{
  "httpStatusCode" : 400,
  "type" : "client.validation",
  "code" : "method.argument.type.mismatch",
  "message" : "Failed to convert value of type 'java.lang.String' to required type 'java.lang.Integer'; nested exception is java.lang.NumberFormatException: For input string: \"AAA\"",
  "apiSubErrors" : [ ],
  "timestamp" : "2025-05-26T05:50:26.276795489Z"
}

Resource failed to be created

If the service-cancellation resource failed to be created, a http status of 422 is returned and the body of the response will list the reason why

GET Response resource failed to be created
HTTP/1.1 422 Unprocessable Entity
Content-Type: application/json
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Length: 411

{
  "httpStatusCode" : 422,
  "type" : "client.validation",
  "code" : "validation",
  "message" : "Validation error",
  "apiSubErrors" : [ {
    "code" : "constraints.service-cancellation.in-error",
    "message" : "Service not in a valid state to cancel.",
    "object" : "ServiceCancellation",
    "field" : "status",
    "rejectedValue" : "IN_ERROR"
  } ],
  "timestamp" : "2025-05-26T05:50:31.054217956Z"
}