CCC API v8.4.0.0

<back to all web services

GetServiceUserUsage

The following routes are available for this service:
GET/api/services/{ServiceGuid}/users/{UserGuid}/usageGet a User usage report.Get a User usage including number of Messages sent and Features used.
GetServiceUserUsage Parameters:
NameParameterData TypeRequiredDescription
ServiceGuidpathGuidYes
UserGuidpathGuidYes
PeriodTypequeryPeriodTypeNoDefaults to Daily.
PeriodqueryDateTimeNoDefaults to yesterdays Date.
GetServiceUserUsageResponse Parameters:
NameParameterData TypeRequiredDescription
ServiceGuidformGuidNo
PeriodTypeformPeriodTypeNo

Allowable Values

  • Daily
  • Monthly
PeriodbodyDateTimeNo
UsagebodyUserUsageNo
BaseResponse Parameters:
NameParameterData TypeRequiredDescription
ResponseStatusformResponseStatusNo
UserUsage Parameters:
NameParameterData TypeRequiredDescription
UserGuidbodyGuidNo
EmailAddressformstringNo
IsAliasbodyBooleanNo
FirstNameformstringNo
LastNameformstringNo
StatusformServiceUserStatusEnum?No

Allowable Values

  • Active
  • Disabled
CreatedOnbodyDateTimeNo
RegisteredOnbodyDateTimeNo
LastLoginbodyDateTimeNo
GroupNameformstringNo
GroupTypeformServiceUserGroupEnum?No

Allowable Values

  • Professional
  • Guest
GroupGuidbodyGuidNo
TotalMessagesSentbodyIntegerNo
TotalMessagesReceivedbodyIntegerNo
TotalAttachmentsCountbodyIntegerNo
TotalAttachmentsSizebodyIntegerNo
TotalInvitationsSentbodyIntegerNo
TotalInvitationsAcceptedbodyIntegerNo
LastToolbarVersionbodyStringNo
InvitedByEmailAddressbodyStringNo
LastMsgSentbodyDateTimeNo
LastMsgRetrievedbodyDateTimeNo
LastActivitybodyDateTimeNo

To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json

To embed the response in a jsonp callback, append ?callback=myCallback

HTTP + JSON

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

GET /api/services/{ServiceGuid}/users/{UserGuid}/usage HTTP/1.1 
Host: api.secure-messaging.com 
Accept: application/json
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{
  "serviceGuid": "00000000000000000000000000000000",
  "periodType": "Daily",
  "period": "0001-01-01T00:00:00Z",
  "usage": {
    "userGuid": "00000000000000000000000000000000",
    "emailAddress": "String",
    "isAlias": false,
    "firstName": "String",
    "lastName": "String",
    "status": "0",
    "createdOn": "0001-01-01T00:00:00Z",
    "registeredOn": "0001-01-01T00:00:00Z",
    "lastLogin": "0001-01-01T00:00:00Z",
    "groupName": "String",
    "groupType": "Professional",
    "groupGuid": "00000000000000000000000000000000",
    "totalMessagesSent": 0,
    "totalMessagesReceived": 0,
    "totalAttachmentsCount": 0,
    "totalAttachmentsSize": 0,
    "totalInvitationsSent": 0,
    "totalInvitationsAccepted": 0,
    "lastToolbarVersion": "String",
    "invitedByEmailAddress": "String",
    "lastMsgSent": "0001-01-01T00:00:00Z",
    "lastMsgRetrieved": "0001-01-01T00:00:00Z",
    "lastActivity": "0001-01-01T00:00:00Z"
  },
  "responseStatus": {
    "errorCode": "String",
    "message": "String",
    "stackTrace": "String",
    "errors": [
      {
        "errorCode": "String",
        "fieldName": "String",
        "message": "String",
        "meta": {
          "String": "String"
        }
      }
    ],
    "meta": {
      "String": "String"
    }
  }
}