# Adform Stale Entity Audit

> >-

- **Type:** Skill
- **Install:** `agentstack add skill-adform-agentic-skills-adform-stale-entity-audit`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [adform](https://agentstack.voostack.com/s/adform)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [adform](https://github.com/adform)
- **Source:** https://github.com/adform/agentic-skills/tree/main/dist/claude/adform-agentic-skills/skills/adform-stale-entity-audit
- **Website:** https://site.adform.com

## Install

```sh
agentstack add skill-adform-agentic-skills-adform-stale-entity-audit
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# Adform stale and orphaned entity audit

Two account hygiene sweeps: campaigns whose end date has passed but whose status is still
active, and RTB line items still active under an inactive or ended order. Both present budget
and governance risk. Read-only — remediation (pause or close) is the user's action.

## Connection & tooling

Runs on the Adform GraphQL MCP. Use `graphql_execute` to run queries. Keep calls sequential
(~1–2s apart).

---

## Sweep 1 — Campaigns past their end date

List active campaigns and compare each `endDate` to today:

```graphql
{
  campaigns(
    advertisers: "71883"
    status: Active
    offset: 0
    limit: 50
  ) {
    campaigns { id name status startDate endDate budget currency }
    totalCount
  }
}
```

Flag any campaign where `endDate` is before today. Check whether it is still spending:

```graphql
{
  campaignDeliveryIndications(id: "3993873") {
    status
    effectiveFlightDailyCost
    effectiveFlightTotalCost
  }
}
```

A non-zero `effectiveFlightDailyCost` means the campaign is still spending after its end date.

---

## Sweep 2 — Orphaned RTB line items

Find inactive or ended orders, then check whether any of their line items are still active:

```graphql
{
  orders(
    campaignId: "3993873"
    active: false
    offset: 0
    limit: 20
  ) {
    orders { id name startDate endDate active }
    totalCount
  }
}
```

List line items under those orders:

```graphql
{
  rtbLineItems(
    orderIds: ["67890"]
    paused: false
    offset: 0
    limit: 20
  ) {
    lineItems { id name paused deleted orderId }
    totalCount
  }
}
```

Check whether any unpaused line item is still spending:

```graphql
{
  rtbLineItemDeliveryIndications(id: "99999") {
    status
    effectiveFlightDailyCost
  }
}
```

---

## Presenting

Two tables. Ghost campaigns: ID, name, end date, days overdue, still spending (daily cost).
Orphaned line items: ID, name, parent order, order status, still spending. Lead with anything
still incurring cost. Frame each row as an action item — pause or close — for the ops owner.

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [adform](https://github.com/adform)
- **Source:** [adform/agentic-skills](https://github.com/adform/agentic-skills)
- **License:** MIT
- **Homepage:** https://site.adform.com

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-adform-agentic-skills-adform-stale-entity-audit
- Seller: https://agentstack.voostack.com/s/adform
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
