Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Status codes provide extra information when a request is made to the MTAPI. The response code will be provided when a request has been successfully completed.

...

Response Headers
{
"cache-control": "no-cache",
"content-length": "123",
"content-type": "application/json; charset=utf-8",
"date": "Tue, 20 Apr 2021 11:28:03 GMT",
"expires": "-1",
"mtapistatus": "-1",
"pragma": "no-cache",
"server": "Microsoft-IIS/8.5",
"x-aspnet-version": "4.0.30319",
"x-powered-by": "ASP.NET"
}

...

Generic/Reusable Statuses - can be used in any controller (901000-902999)

  • Operation you performed came across internal error, if you keep seeing error contact your lead or support
    InternalError = 901000 // instead of disclosing details, this error may be used

  • MtapiSettingError = 901001 // instead of disclosing details, this error may be used

  • ArgumentError = 901002, // use this status code for argument related errors where the app used to throw "ArgumentException", where error handler logs error however return a bad request to the caller

  • EnrollmentInServiceRequired = 901003 // use this status code if an

  • Error in MTAPI service setting, contact MTAPI team to get it resolved
    MtapiSettingError = 901001

  • Operation you tried to perform came across argument related error - such as missing argument or invalid value
    ArgumentError = 901002

  • An operation cannot be performed because it requires users to be enrolled in a service
    EnrollmentInServiceRequired = 901003

  • Must be a valid province
    NoServiceWithReadUserPermission = 901008

  • In a filter, at least one value is invalid. For further details, refer documentation of an operation where this error occur or contact MTAPI team
    InvalidValueInFilter = 901005

  • Authorization error
    AuthorizationError = 901006

  • CurrentUserId does not belong to a real application user
    UserIdNotBelongingToApplication = 901005

  • ApplicationName is not available
    ApplicationNameNotAvailable = 901006

  • Request context is not available
    RequestContextNotAvailable = 901007

  • User is not enrolled in any service with read user permission
    NoServiceWithReadUserPermission = 901008

App Controller (603000 - 603999)

...

File Attachments Controller (607000-607999)

  • InvalidServiceRequestId = 607000 Note: app uses ServiceRequestNotFound = 4041001

  • Md5HashNotMatching = 607000
    MD5 hash does not match.

  • FileNameWithUnsupportedCharacters = 607001
    File name consists unsupported characters.

  • VirusScanResultBlocked = 607002
    Virus Scan Result - Blocked.

  • InvalidVirusScanUrl = 607004 Note: app uses MtapiSettingError = 901001

  • MISSING_WORKFLOW_RULE = 7005 Note: app uses MtapiSettingError = 901001

Invoices Controller (608000-608999)

...

Users Controller (620000-620999)

Note: Not implemented yet.

  • InvalidUserId = 620000

  • InvalidUserType = 620001Call to check whether user exists or not has failed
    UserExistsFailed = 620001

  • Call to check whether user exists or not has failed
    UserExistsFailed = 620001

  • Associate internal user to organization failed
    AssociateInternalUserToOrganizationFails = 620003

  • Retrieving users has failed
    RetrievingUsersFailed = 62000

  • Retrieving user using id has failed
    RetrievingUserByIdFailed = 620005

  • Retrieving user using PKI has failed
    RetrievingUserByPkiFailed = 620006

  • Retrieving users using email has failed
    RetrievingUsersByEmailFailed = 620007

  • Retrieving user using passed credentials has failed
    RetrievingUserByAuthInfoFailed = 620008

  • Retrieving request for user has failed
    RetrievingRequestsForUserFailed = 620009

  • Adding or updating user information has failed
    AddingOrUpdatingUserFailed = 620010

  • Deleting user has failed
    DeletingUserFailed = 620011

  • Retrieving organizations information for a user has failed
    RetrievingOrganizationsForUserFailed = 620012

  • Retrieving business systems information for a user has failed
    RetrievingBusinessSystemsForUserFailed = 620013

  • Retrieving services for a user has failed
    RetrievingServicesByUserFailed = 620014

  • Adding permission to service has failed
    AddingPermissionToServiceFailed = 620015

  • Deleting service permission has failed
    DeletingServicePermissionFailed = 620016

  • Retrieving notices for a user has failed
    RetrievingNoticesForUserFailed = 620017

  • Retrieving permissions of a user has failed
    RetrievingPermissionsByUserFailed = 620018

  • Retrieving permissions for a user's service has failed
    RetrievingPermissionsByUserAndServiceFailed = 620019

  • Searching users has failed
    UserSearchFailed = 620019

Virus Scan Controller (621000-621999)

...