---
updatedAt: 2025-06-09T22:43:08.000Z
agentTools:
  projectIndex: https://docs.zenloop.com/llms.txt
---

# Get Summary of Survey Groups

This endpoint is used for fetching basic survey data and NPS scores.

```json Example request
{
  "date_shortcut": "all_time"
}
```

## Response attributes

| Attribute                                   |  Type  | Description                                                                             |
| :------------------------------------------ | :----: | :-------------------------------------------------------------------------------------- |
| **survey\_group**                           | object | Survey group information data.                                                          |
| survey\_group.**name**                      | string | Survey group title.                                                                     |
| survey\_group.**public\_hash\_id**          | string | Survey group public hash id used to identify survey group.                              |
| survey\_group.**promoters**                 | object | Summary data about promoters from survey group answers.                                 |
| survey.promoters.**percentage**             | number | Percentage of answers that were promoters.                                              |
| survey\_group.promoters.**delta**           | number | Promoters delta - describing the +/- change for the similar period we measure against.  |
| survey\_group.**passives**                  | object | Summary data about passives from survey group answers.                                  |
| survey\_group.passives.**percentage**       | number | Percentage of answers that were passives.                                               |
| survey\_group.passives.**delta**            | number | Passives delta - describing the +/- change for the similar period we measure against.   |
| survey\_group.**number\_of\_responses**     | number | Number of answers.                                                                      |
| survey\_group.**nps**                       | object | Summary data about NPS from survey group answers.                                       |
| survey\_group.nps.**percentage**            | number | The NPS score.                                                                          |
| survey\_group.nps.**delta**                 | number | NPS delta - describing the +/- change for the similar period we measure against.        |
| survey\_group.**inserted\_at**              |  date  | Survey group creation date.                                                             |
| survey\_group.**detractors**                | object | Summary data about detractors from survey group answers.                                |
| survey\_group.detractors.**percentage**     | number | Percentage of answers that were detractors.                                             |
| survey\_group.detractors.**delta**          | number | Detractors delta - describing the +/- change for the similar period we measure against. |
| survey\_group.**surveys**                   | object | Surveys information data.                                                               |
| survey\_groups.surveys.**title**            | string | Survey title.                                                                           |
| survey\_groups.surveys.**status**           | string | Survey status. One of: `draft`, `active`.                                               |
| survey\_groups.surveys.**public\_hash\_id** | string | Survey public hash id used to identify survey.                                          |
| survey\_groups.surveys.**inserted\_at**     |  date  | Survey creation date.                                                                   |

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "api",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://api.zenloop.com"
    }
  ],
  "security": [
    {}
  ],
  "paths": {
    "/v1/survey_groups/{survey_group_id}": {
      "get": {
        "summary": "Get Summary of Survey Groups",
        "description": "This endpoint is used for fetching basic survey data and NPS scores.",
        "operationId": "get-summary-of-survey-groups",
        "parameters": [
          {
            "name": "survey_group_id",
            "in": "path",
            "description": "Unique ID of a survey",
            "schema": {
              "type": "string"
            },
            "required": true
          },
          {
            "name": "date_shortcut",
            "in": "query",
            "description": "Date range for which we want to fetch answers. Allowed values: `today`, `yesterday`, `last_week`, `last_month`, `last_7_days`, `last_30_days`, `all_time`, `custom`",
            "schema": {
              "type": "string",
              "default": "all_time"
            }
          },
          {
            "name": "Authorization",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "default": "Bearer <token>"
            }
          },
          {
            "name": "date_from",
            "in": "query",
            "description": "Parameter required when date_shortcut is set to `custom`. Filters answers only received after specific datetime. Format: `2021-10-24T03:30:30Z` or `2021-10-24`",
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "date_to",
            "in": "query",
            "description": "Parameter required when date_shortcut is set to `custom`. Filters answers only received before specific datetime. Format: `2021-10-24T03:30:30Z` or `2021-10-24`",
            "schema": {
              "type": "string",
              "format": "date"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{  \n  \"survey_group\":{  \n    \"surveys\":[  \n      {  \n        \"public_hash_id\":\"ZGtKWGNTVEpqSnJmeENKbUlYZ2hKT2Y2dE5QbHpVRXN1cUQwRmFvN3Z3OD0=\"\n      }\n    ],\n    \"public_hash_id\":\"SUhsSW5ZOFBaZ0xPNk1XWWhnV094Z1dsUUhtMFp4eFpNa0FHcWFqd2JCZz0=\",\n    \"promoters\":{  \n      \"percentage\":50,\n      \"delta\":0\n    },\n    \"passives\":{  \n      \"percentage\":6,\n      \"delta\":0\n    },\n    \"number_of_responses\":18,\n    \"nps\":{  \n      \"percentage\":6,\n      \"delta\":0\n    },\n    \"name\":\"Normal Group\",\n    \"inserted_at\":\"2018-02-23T10:46:28Z\",\n    \"detractors\":{  \n      \"percentage\":44,\n      \"delta\":0\n    }\n  }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "survey_group": {
                      "type": "object",
                      "properties": {
                        "surveys": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "public_hash_id": {
                                "type": "string",
                                "example": "ZGtKWGNTVEpqSnJmeENKbUlYZ2hKT2Y2dE5QbHpVRXN1cUQwRmFvN3Z3OD0="
                              }
                            }
                          }
                        },
                        "public_hash_id": {
                          "type": "string",
                          "example": "SUhsSW5ZOFBaZ0xPNk1XWWhnV094Z1dsUUhtMFp4eFpNa0FHcWFqd2JCZz0="
                        },
                        "promoters": {
                          "type": "object",
                          "properties": {
                            "percentage": {
                              "type": "integer",
                              "example": 50,
                              "default": 0
                            },
                            "delta": {
                              "type": "integer",
                              "example": 0,
                              "default": 0
                            }
                          }
                        },
                        "passives": {
                          "type": "object",
                          "properties": {
                            "percentage": {
                              "type": "integer",
                              "example": 6,
                              "default": 0
                            },
                            "delta": {
                              "type": "integer",
                              "example": 0,
                              "default": 0
                            }
                          }
                        },
                        "number_of_responses": {
                          "type": "integer",
                          "example": 18,
                          "default": 0
                        },
                        "nps": {
                          "type": "object",
                          "properties": {
                            "percentage": {
                              "type": "integer",
                              "example": 6,
                              "default": 0
                            },
                            "delta": {
                              "type": "integer",
                              "example": 0,
                              "default": 0
                            }
                          }
                        },
                        "name": {
                          "type": "string",
                          "example": "Normal Group"
                        },
                        "inserted_at": {
                          "type": "string",
                          "example": "2018-02-23T10:46:28Z"
                        },
                        "detractors": {
                          "type": "object",
                          "properties": {
                            "percentage": {
                              "type": "integer",
                              "example": 44,
                              "default": 0
                            },
                            "delta": {
                              "type": "integer",
                              "example": 0,
                              "default": 0
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "400",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{  \n  \"error\":{  \n    \"title\":\"Invalid request body.\",\n    \"status\":400,\n    \"links\":{  \n      \"documentation\":\"https://docs.zenloop.com/v1.0/reference#get-summary-of-survey-group\"\n    },\n    \"details\":[  \n      {  \n        \"pointer\":\"/date_shortcut\",\n        \"detail\":\"Value \\\"invalid\\\" is not allowed in enum.\"\n      }\n    ],\n    \"code\":\"INVALID_REQUEST\"\n  }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "object",
                      "properties": {
                        "title": {
                          "type": "string",
                          "example": "Invalid request body."
                        },
                        "status": {
                          "type": "integer",
                          "example": 400,
                          "default": 0
                        },
                        "links": {
                          "type": "object",
                          "properties": {
                            "documentation": {
                              "type": "string",
                              "example": "https://docs.zenloop.com/v1.0/reference#get-summary-of-survey-group"
                            }
                          }
                        },
                        "details": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "pointer": {
                                "type": "string",
                                "example": "/date_shortcut"
                              },
                              "detail": {
                                "type": "string",
                                "example": "Value \"invalid\" is not allowed in enum."
                              }
                            }
                          }
                        },
                        "code": {
                          "type": "string",
                          "example": "INVALID_REQUEST"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "401",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"error\": {\n    \"status\": 401,\n    \"code\": \"UNAUTHORIZED\",\n    \"title\": \"Invalid or expired token.\"\n  }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "integer",
                          "example": 401,
                          "default": 0
                        },
                        "code": {
                          "type": "string",
                          "example": "UNAUTHORIZED"
                        },
                        "title": {
                          "type": "string",
                          "example": "Invalid or expired token."
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "404",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{  \n  \"error\":{  \n    \"title\":\"SurveyGroup not found.\",\n    \"status\":404,\n    \"code\":\"NOT_FOUND\"\n  }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "object",
                      "properties": {
                        "title": {
                          "type": "string",
                          "example": "SurveyGroup not found."
                        },
                        "status": {
                          "type": "integer",
                          "example": 404,
                          "default": 0
                        },
                        "code": {
                          "type": "string",
                          "example": "NOT_FOUND"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "429": {
            "description": "429",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"error\": {\n    \"status\": 429,\n    \"code\": \"TOO_MANY_REQUESTS\",\n    \"title\": \"Rate limit exceeded.\"\n  }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "object",
                      "properties": {
                        "status": {
                          "type": "integer",
                          "example": 429,
                          "default": 0
                        },
                        "code": {
                          "type": "string",
                          "example": "TOO_MANY_REQUESTS"
                        },
                        "title": {
                          "type": "string",
                          "example": "Rate limit exceeded."
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false
      }
    }
  },
  "x-readme": {
    "headers": [
      {
        "key": "Content-Type",
        "value": "application/json"
      }
    ],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```