For AI agents: A markdown version of this page is available at https://dnd37xeb23o8n.cloudfront.net/jen.gilbert/astro-base/fr/api/latest/product-analytics/list-the-entities-behind-a-retention-cell.md. A documentation index is available at /llms.txt.
Language
Datadog site

List the entities behind a retention cell

WARNINGNote: This endpoint is in preview and is subject to change. If you have any feedback, contact Datadog support.
POSThttps://api.datadoghq.com/api/v2/product-analytics/retention/listhttps://api.us3.datadoghq.com/api/v2/product-analytics/retention/listhttps://api.us5.datadoghq.com/api/v2/product-analytics/retention/listhttps://api.datadoghq.eu/api/v2/product-analytics/retention/listhttps://api.ap1.datadoghq.com/api/v2/product-analytics/retention/listhttps://api.ap2.datadoghq.com/api/v2/product-analytics/retention/listhttps://api.uk1.datadoghq.com/api/v2/product-analytics/retention/listhttps://api.ddog-gov.com/api/v2/product-analytics/retention/listhttps://api.us2.ddog-gov.com/api/v2/product-analytics/retention/list

Présentation

List the individual users or accounts counted in one cell of the retention grid. Set computation_scope to the cohort and return period you want to examine.

This endpoint requires the rum_apps_read permission.

Requête

Body Data (required)

The retention list query.

Champ
Type
Description
data [required]
object

The single JSON:API resource carrying a retention list query. Its attributes hold the time window, the cell to list, and the columns to return for each entity.

Réponse

OK

Response for a retention list query.

Champ
Type
Description
data [required]
object

The single JSON:API resource holding the entities behind one retention cell. Its attributes contain the entity whose retention was measured and one row per matching entity.

Exemple de code

List the entities behind a retention cell
# Set your Datadog site and credentials
export DD_SITE="datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X POST "https://api.${DD_SITE}/api/v2/product-analytics/retention/list" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "from": 1756425600000,
      "query": {
        "columns": [
          {
            "field": {
              "path": "@usr.email"
            }
          }
        ],
        "computation_scope": {
          "cohort_target": {
            "type": "index",
            "value": 0
          },
          "return_period_target": {
            "type": "index",
            "value": 1
          },
          "type": "cell"
        },
        "limit": 100,
        "search": {
          "cohort_criteria": {
            "base_query": {
              "data_source": "product_analytics",
              "search": {
                "query": "@type:view @view.name:Signup"
              }
            },
            "time_interval": {
              "type": "calendar",
              "value": {
                "quantity": 1,
                "type": "week"
              }
            }
          },
          "retention_entity": "@usr.id",
          "return_condition": "conversion_on_or_after"
        }
      },
      "to": 1756857600000
    },
    "type": "retention_list_request"
  }
}
EOF
# Set your Datadog site and credentials
export DD_SITE="us3.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X POST "https://api.${DD_SITE}/api/v2/product-analytics/retention/list" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "from": 1756425600000,
      "query": {
        "columns": [
          {
            "field": {
              "path": "@usr.email"
            }
          }
        ],
        "computation_scope": {
          "cohort_target": {
            "type": "index",
            "value": 0
          },
          "return_period_target": {
            "type": "index",
            "value": 1
          },
          "type": "cell"
        },
        "limit": 100,
        "search": {
          "cohort_criteria": {
            "base_query": {
              "data_source": "product_analytics",
              "search": {
                "query": "@type:view @view.name:Signup"
              }
            },
            "time_interval": {
              "type": "calendar",
              "value": {
                "quantity": 1,
                "type": "week"
              }
            }
          },
          "retention_entity": "@usr.id",
          "return_condition": "conversion_on_or_after"
        }
      },
      "to": 1756857600000
    },
    "type": "retention_list_request"
  }
}
EOF
# Set your Datadog site and credentials
export DD_SITE="us5.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X POST "https://api.${DD_SITE}/api/v2/product-analytics/retention/list" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "from": 1756425600000,
      "query": {
        "columns": [
          {
            "field": {
              "path": "@usr.email"
            }
          }
        ],
        "computation_scope": {
          "cohort_target": {
            "type": "index",
            "value": 0
          },
          "return_period_target": {
            "type": "index",
            "value": 1
          },
          "type": "cell"
        },
        "limit": 100,
        "search": {
          "cohort_criteria": {
            "base_query": {
              "data_source": "product_analytics",
              "search": {
                "query": "@type:view @view.name:Signup"
              }
            },
            "time_interval": {
              "type": "calendar",
              "value": {
                "quantity": 1,
                "type": "week"
              }
            }
          },
          "retention_entity": "@usr.id",
          "return_condition": "conversion_on_or_after"
        }
      },
      "to": 1756857600000
    },
    "type": "retention_list_request"
  }
}
EOF
# Set your Datadog site and credentials
export DD_SITE="datadoghq.eu"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X POST "https://api.${DD_SITE}/api/v2/product-analytics/retention/list" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "from": 1756425600000,
      "query": {
        "columns": [
          {
            "field": {
              "path": "@usr.email"
            }
          }
        ],
        "computation_scope": {
          "cohort_target": {
            "type": "index",
            "value": 0
          },
          "return_period_target": {
            "type": "index",
            "value": 1
          },
          "type": "cell"
        },
        "limit": 100,
        "search": {
          "cohort_criteria": {
            "base_query": {
              "data_source": "product_analytics",
              "search": {
                "query": "@type:view @view.name:Signup"
              }
            },
            "time_interval": {
              "type": "calendar",
              "value": {
                "quantity": 1,
                "type": "week"
              }
            }
          },
          "retention_entity": "@usr.id",
          "return_condition": "conversion_on_or_after"
        }
      },
      "to": 1756857600000
    },
    "type": "retention_list_request"
  }
}
EOF
# Set your Datadog site and credentials
export DD_SITE="ap1.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X POST "https://api.${DD_SITE}/api/v2/product-analytics/retention/list" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "from": 1756425600000,
      "query": {
        "columns": [
          {
            "field": {
              "path": "@usr.email"
            }
          }
        ],
        "computation_scope": {
          "cohort_target": {
            "type": "index",
            "value": 0
          },
          "return_period_target": {
            "type": "index",
            "value": 1
          },
          "type": "cell"
        },
        "limit": 100,
        "search": {
          "cohort_criteria": {
            "base_query": {
              "data_source": "product_analytics",
              "search": {
                "query": "@type:view @view.name:Signup"
              }
            },
            "time_interval": {
              "type": "calendar",
              "value": {
                "quantity": 1,
                "type": "week"
              }
            }
          },
          "retention_entity": "@usr.id",
          "return_condition": "conversion_on_or_after"
        }
      },
      "to": 1756857600000
    },
    "type": "retention_list_request"
  }
}
EOF
# Set your Datadog site and credentials
export DD_SITE="ap2.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X POST "https://api.${DD_SITE}/api/v2/product-analytics/retention/list" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "from": 1756425600000,
      "query": {
        "columns": [
          {
            "field": {
              "path": "@usr.email"
            }
          }
        ],
        "computation_scope": {
          "cohort_target": {
            "type": "index",
            "value": 0
          },
          "return_period_target": {
            "type": "index",
            "value": 1
          },
          "type": "cell"
        },
        "limit": 100,
        "search": {
          "cohort_criteria": {
            "base_query": {
              "data_source": "product_analytics",
              "search": {
                "query": "@type:view @view.name:Signup"
              }
            },
            "time_interval": {
              "type": "calendar",
              "value": {
                "quantity": 1,
                "type": "week"
              }
            }
          },
          "retention_entity": "@usr.id",
          "return_condition": "conversion_on_or_after"
        }
      },
      "to": 1756857600000
    },
    "type": "retention_list_request"
  }
}
EOF
# Set your Datadog site and credentials
export DD_SITE="uk1.datadoghq.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X POST "https://api.${DD_SITE}/api/v2/product-analytics/retention/list" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "from": 1756425600000,
      "query": {
        "columns": [
          {
            "field": {
              "path": "@usr.email"
            }
          }
        ],
        "computation_scope": {
          "cohort_target": {
            "type": "index",
            "value": 0
          },
          "return_period_target": {
            "type": "index",
            "value": 1
          },
          "type": "cell"
        },
        "limit": 100,
        "search": {
          "cohort_criteria": {
            "base_query": {
              "data_source": "product_analytics",
              "search": {
                "query": "@type:view @view.name:Signup"
              }
            },
            "time_interval": {
              "type": "calendar",
              "value": {
                "quantity": 1,
                "type": "week"
              }
            }
          },
          "retention_entity": "@usr.id",
          "return_condition": "conversion_on_or_after"
        }
      },
      "to": 1756857600000
    },
    "type": "retention_list_request"
  }
}
EOF
# Set your Datadog site and credentials
export DD_SITE="ddog-gov.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X POST "https://api.${DD_SITE}/api/v2/product-analytics/retention/list" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "from": 1756425600000,
      "query": {
        "columns": [
          {
            "field": {
              "path": "@usr.email"
            }
          }
        ],
        "computation_scope": {
          "cohort_target": {
            "type": "index",
            "value": 0
          },
          "return_period_target": {
            "type": "index",
            "value": 1
          },
          "type": "cell"
        },
        "limit": 100,
        "search": {
          "cohort_criteria": {
            "base_query": {
              "data_source": "product_analytics",
              "search": {
                "query": "@type:view @view.name:Signup"
              }
            },
            "time_interval": {
              "type": "calendar",
              "value": {
                "quantity": 1,
                "type": "week"
              }
            }
          },
          "retention_entity": "@usr.id",
          "return_condition": "conversion_on_or_after"
        }
      },
      "to": 1756857600000
    },
    "type": "retention_list_request"
  }
}
EOF
# Set your Datadog site and credentials
export DD_SITE="us2.ddog-gov.com"
# Use a Personal Access Token or Service Access Token
export DD_BEARER_TOKEN="<PERSONAL_ACCESS_TOKEN OR SERVICE_ACCESS_TOKEN>"

curl -X POST "https://api.${DD_SITE}/api/v2/product-analytics/retention/list" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer ${DD_BEARER_TOKEN}" \
-d @- << EOF
{
  "data": {
    "attributes": {
      "from": 1756425600000,
      "query": {
        "columns": [
          {
            "field": {
              "path": "@usr.email"
            }
          }
        ],
        "computation_scope": {
          "cohort_target": {
            "type": "index",
            "value": 0
          },
          "return_period_target": {
            "type": "index",
            "value": 1
          },
          "type": "cell"
        },
        "limit": 100,
        "search": {
          "cohort_criteria": {
            "base_query": {
              "data_source": "product_analytics",
              "search": {
                "query": "@type:view @view.name:Signup"
              }
            },
            "time_interval": {
              "type": "calendar",
              "value": {
                "quantity": 1,
                "type": "week"
              }
            }
          },
          "retention_entity": "@usr.id",
          "return_condition": "conversion_on_or_after"
        }
      },
      "to": 1756857600000
    },
    "type": "retention_list_request"
  }
}
EOF