> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://developer.icepanel.io/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://developer.icepanel.io/_mcp/server.

# By Type

GET https://api.icepanel.io/v1/organizations/{organizationId}/logs/stats/by-type

List total counts of actions for each action type (e.g. diagram-content-update, model-object-create)

Reference: https://developer.icepanel.io/api-reference/organizations/logs/stats/by-type

## Authentication

- `X-API-Key` header (required) — API key authentication
- `Authorization` header (bearer token, required) — Bearer token authentication

## Request

### Path parameters

- `organizationId` (string, required)

### Query parameters

- `filter` (OrganizationLogStatsFilter, optional)
- `period` (enum, optional)
  - Allowed values: `day`, `week`, `month`, `year`, `all`

## Response

### 200

OK

- `contributors` (map from string to ActionLogStatsContributor, required)
- `dates` (list of OrganizationLogStatsDateByType, required)
- `totalCount` (double, required)

## Errors

### 400 Bad Request Error

Bad Request

- `message` (string, required)
- `code` (string, optional)
- `errors` (list of string, optional)

### 401 Unauthorized Error

Unauthorized

- `message` (string, required)
- `code` (string, optional)
- `errors` (list of string, optional)

### 403 Forbidden Error

Forbidden

- `message` (string, required)
- `code` (string, optional)
- `errors` (list of string, optional)

### 404 Not Found Error

Not Found

- `message` (string, required)
- `code` (string, optional)
- `errors` (list of string, optional)

### 422 Unprocessable Entity Error

Unprocessable Entity

- `message` (string, required)
- `code` (string, optional)
- `errors` (list of string, optional)

### 429 Too Many Requests Error

Resource Exhausted

- `message` (string, required)
- `code` (string, optional)
- `errors` (list of string, optional)

### 500 Internal Server Error

Internal Server

- `message` (string, required)
- `code` (string, optional)
- `errors` (list of string, optional)

## Types

### OrganizationLogStatsFilter

- `actionType` (OrganizationLogStatsFilterActionType, optional) — type of action that was performed, eg: diagram-content-update or model-object-create
- `endAtDate` (datetime, optional)
- `entityId` (OrganizationLogStatsFilterEntityId, optional) — id of the entity to lookup, eg: id of the tag being created, or id of the model object being updated
- `performedBy` (OrganizationLogStatsFilterPerformedBy, optional)
- `performedById` (OrganizationLogStatsFilterPerformedById, optional) — id of the user or api key who performed the action
- `startAtDate` (datetime, optional)

### ActionLogStatsContributor

- `contributedAt` (datetime, required)
- `count` (double, required)
- `id` (string, required)
- `type` (enum, required)
  - Allowed values: `user`, `api-key`, `notification-key`, `service`
- `name` (string, optional)

### OrganizationLogStatsDateByType

- `actions` (map from string to OrganizationLogStatsItemByType, required)
- `date` (datetime, required)

### OrganizationLogStatsFilterActionType

type of action that was performed, eg: diagram-content-update or model-object-create

- enum
  - Allowed values: `api-key-create`, `api-key-delete`, `api-key-update`, `oauth-consent-deny`, `oauth-consent-grant`, `organization-create`, `organization-delete`, `organization-update`, `organization-user-add`, `organization-user-invite-create`, `organization-user-invite-revoke`, `organization-user-remove`, `organization-user-update`, `team-create`, `team-delete`, `team-update`, `user-login`, `user-login-failed`, `user-logout`, `comment-create`, `comment-delete`, `comment-reply-create`, `comment-reply-delete`, `comment-reply-update`, `comment-update`, `diagram-content-create`, `diagram-content-delete`, `diagram-content-update`, `diagram-content-view`, `diagram-create`, `diagram-delete`, `diagram-export`, `diagram-group-create`, `diagram-group-delete`, `diagram-group-update`, `diagram-update`, `domain-create`, `domain-delete`, `domain-update`, `draft-create`, `draft-delete`, `draft-merge`, `draft-task-create`, `draft-update`, `draft-view`, `flow-create`, `flow-delete`, `flow-update`, `flow-view`, `landscape-copy`, `landscape-create`, `landscape-delete`, `landscape-duplicate`, `landscape-export`, `landscape-import`, `landscape-update`, `model-connection-create`, `model-connection-delete`, `model-connection-update`, `model-connections-export`, `model-object-create`, `model-object-delete`, `model-object-dependencies-export`, `model-object-update`, `model-objects-export`, `share-link-create`, `share-link-delete`, `share-link-update`, `tag-create`, `tag-delete`, `tag-group-create`, `tag-group-delete`, `tag-group-update`, `tag-update`, `version-create`, `version-delete`, `version-revert-create`
- list of enum
  - Allowed values: `api-key-create`, `api-key-delete`, `api-key-update`, `oauth-consent-deny`, `oauth-consent-grant`, `organization-create`, `organization-delete`, `organization-update`, `organization-user-add`, `organization-user-invite-create`, `organization-user-invite-revoke`, `organization-user-remove`, `organization-user-update`, `team-create`, `team-delete`, `team-update`, `user-login`, `user-login-failed`, `user-logout`, `comment-create`, `comment-delete`, `comment-reply-create`, `comment-reply-delete`, `comment-reply-update`, `comment-update`, `diagram-content-create`, `diagram-content-delete`, `diagram-content-update`, `diagram-content-view`, `diagram-create`, `diagram-delete`, `diagram-export`, `diagram-group-create`, `diagram-group-delete`, `diagram-group-update`, `diagram-update`, `domain-create`, `domain-delete`, `domain-update`, `draft-create`, `draft-delete`, `draft-merge`, `draft-task-create`, `draft-update`, `draft-view`, `flow-create`, `flow-delete`, `flow-update`, `flow-view`, `landscape-copy`, `landscape-create`, `landscape-delete`, `landscape-duplicate`, `landscape-export`, `landscape-import`, `landscape-update`, `model-connection-create`, `model-connection-delete`, `model-connection-update`, `model-connections-export`, `model-object-create`, `model-object-delete`, `model-object-dependencies-export`, `model-object-update`, `model-objects-export`, `share-link-create`, `share-link-delete`, `share-link-update`, `tag-create`, `tag-delete`, `tag-group-create`, `tag-group-delete`, `tag-group-update`, `tag-update`, `version-create`, `version-delete`, `version-revert-create`

### OrganizationLogStatsFilterEntityId

id of the entity to lookup, eg: id of the tag being created, or id of the model object being updated

- string
- list of string

### OrganizationLogStatsFilterPerformedBy

- enum
  - Allowed values: `user`, `api-key`, `notification-key`, `service`
- list of enum
  - Allowed values: `user`, `api-key`, `notification-key`, `service`

### OrganizationLogStatsFilterPerformedById

id of the user or api key who performed the action

- string
- list of string

### OrganizationLogStatsItemByType

- `contributors` (map from string to ActionLogStatsContributor, required)
- `count` (double, required)
- `type` (enum, required) — type of action that was performed, eg: diagram-content-update or model-object-create
  - Allowed values: `api-key-create`, `api-key-delete`, `api-key-update`, `oauth-consent-deny`, `oauth-consent-grant`, `organization-create`, `organization-delete`, `organization-update`, `organization-user-add`, `organization-user-invite-create`, `organization-user-invite-revoke`, `organization-user-remove`, `organization-user-update`, `team-create`, `team-delete`, `team-update`, `user-login`, `user-login-failed`, `user-logout`, `comment-create`, `comment-delete`, `comment-reply-create`, `comment-reply-delete`, `comment-reply-update`, `comment-update`, `diagram-content-create`, `diagram-content-delete`, `diagram-content-update`, `diagram-content-view`, `diagram-create`, `diagram-delete`, `diagram-export`, `diagram-group-create`, `diagram-group-delete`, `diagram-group-update`, `diagram-update`, `domain-create`, `domain-delete`, `domain-update`, `draft-create`, `draft-delete`, `draft-merge`, `draft-task-create`, `draft-update`, `draft-view`, `flow-create`, `flow-delete`, `flow-update`, `flow-view`, `landscape-copy`, `landscape-create`, `landscape-delete`, `landscape-duplicate`, `landscape-export`, `landscape-import`, `landscape-update`, `model-connection-create`, `model-connection-delete`, `model-connection-update`, `model-connections-export`, `model-object-create`, `model-object-delete`, `model-object-dependencies-export`, `model-object-update`, `model-objects-export`, `share-link-create`, `share-link-delete`, `share-link-update`, `tag-create`, `tag-delete`, `tag-group-create`, `tag-group-delete`, `tag-group-update`, `tag-update`, `version-create`, `version-delete`, `version-revert-create`

## Examples

**Response**

```json
{
  "contributors": {},
  "dates": [
    {
      "actions": {},
      "date": "2024-01-15T09:30:00Z"
    }
  ],
  "totalCount": 1.1
}
```

**SDK Code**

```python
import requests

url = "https://api.icepanel.io/v1/organizations/organizationId/logs/stats/by-type"

headers = {"X-API-Key": "<apiKey>"}

response = requests.get(url, headers=headers)

print(response.json())
```

```go
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.icepanel.io/v1/organizations/organizationId/logs/stats/by-type"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("X-API-Key", "<apiKey>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```csharp
using RestSharp;

var client = new RestClient("https://api.icepanel.io/v1/organizations/organizationId/logs/stats/by-type");
var request = new RestRequest(Method.GET);
request.AddHeader("X-API-Key", "<apiKey>");
IRestResponse response = client.Execute(request);
```