Overview
The V3 Api is a REST-like API to the MVNO system.
The API is divided into distinct areas based on the business scenario.
Click here to see the method description.
Response Codes
The following response codes are used by all methods in V3 API unless otherwise noted.
-
HTTP code 200 is used to indicate that an operation was successfully performed.
If the operation was a POST then the response usually have some content in the body part.
-
HTTP code 400 is used to indicate that there was problem with the request.
The body part will contain some description of the problem.
-
HTTP code 404 usually means is used to indicate that some resource could not be found.
-
HTTP code 422 is used to indicate that your data is correct, but there was some internal problem with them.
For instance an id might point to a resource that have expired, or maybe two different ids in the data have some internal
relationship that have been violated. Look for the X-Mvno-Error-Code HTTP header value for a numeric error code.
-
HTTP code 500 is sent back if we encounter some internal error.
Resource format
The resources are returned as JSON documents.
{
"TicketId": "db65db8c-3af9-3000-b992-39d0ea553442",
"ExpiryMonth": 6,
"ExpiryYear": 24,
"TruncatedCardNumber": "0000",
"CardType": "V-DK",
}
DataType formats
DataTypes are formatted according to the following rules:
- NULL's are passed in as all lower-case letters eg. null.
- Dates with no time part are sent as strings and must comply with the format YYYY-MM-DD eg. "2015-12-31".
- Date & time are sent as strings and must comply with the format YYYY-MM-DD HH:MM:SS eg. "2015-12-31 14:59:59".
- CPR-numbers are sent as string and follow the format \d{10} eg. "1810711234".
- CVR-numbers are sent as string and follow the format \d{8} eg. "19433692".
Tracing context (Optional)
A correlation header can be included in any request, and will be saved to our request log for traceability and debugging. The id must be in the form of a Guid. For instance:
X-Correlation-Id: 6f5ef4ca-4404-4f52-b6df-01cb63b6b985
(Obsolete) For backward compability the X-Context-Id header can still be included until further notice. There are no restrictions to the format of this header but Guid is recommended. For instance:
X-Context-Id: 6f5ef4ca-4404-4f52-b6df-01cb63b6b985
Tracking assisted operations (Optional)
If the api is used by employees on behalf of the user, the employee email can be included for traceablity. The email should refer to a user created in the MVNO system. For instance:
X-User-Id: salesteammember1@mvno.dk
Scenarios