> ## Documentation Index
> Fetch the complete documentation index at: https://docs.earthcare.network/llms.txt
> Use this file to discover all available pages before exploring further.

# Decide a Home Action

> Maps `{status: accepted|dismissed|acted, payload?}` onto the existing Recommendation PATCH (`approve` / `dismiss` / `edit`). `accepted` and `acted` both record status=acted (the Home Accept verb). Optional `payload` is merged first (edit is not approve).




## OpenAPI

````yaml /api/openapi.yaml patch /home/actions/{id}/
openapi: 3.0.3
info:
  title: Earth Care Network API
  version: v1
  description: >
    REST API for the Earth Care Network platform — directory, CRM, context,
    metering/credits, and the prospecting engine.


    This is a **curated** reference covering the headline endpoints with
    accurate paths, methods, auth, and representative request/response bodies.
    ECN's API is largely function-based (DRF `@api_view`/`APIView` without
    serializers), so the raw drf-spectacular dump is sparse today; as the v2
    refactor migrates views to serializer-backed generics, this file is
    superseded by the generated schema (`manage.py spectacular --settings
    ecn.settings_docs`). See https://docs.earthcare.network for guides and the
    MCP surface.
servers:
  - url: https://earthcare.network/api/v1
    description: Production
  - url: https://test.earthcare.network/api/v1
    description: Test
  - url: http://localhost:8000/api/v1
    description: Local
security:
  - TokenAuth: []
tags:
  - name: Auth
    description: Authentication and the current user.
  - name: Directory
    description: The public directory of regenerative businesses.
  - name: Context
    description: AI-ready Context Packs.
  - name: CRM
    description: Contacts, deals, and tasks.
  - name: AI
    description: Metered AI execution through the gateway.
  - name: Credits
    description: Wallet, rate cards, and the usage ledger.
  - name: Prospecting
    description: Go-to-market profiles and lead discovery with buying signals.
  - name: MCP
    description: MCP API key management.
  - name: Automation
    description: Workflow automation.
  - name: Home
    description: V5 Home Growth — purpose, OKRs, honest money, and Actions.
paths:
  /home/actions/{id}/:
    patch:
      tags:
        - Home
      summary: Decide a Home Action
      description: >
        Maps `{status: accepted|dismissed|acted, payload?}` onto the existing
        Recommendation PATCH (`approve` / `dismiss` / `edit`). `accepted` and
        `acted` both record status=acted (the Home Accept verb). Optional
        `payload` is merged first (edit is not approve).
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
        - $ref: '#/components/parameters/OrgId'
        - name: business_slug
          in: query
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                status:
                  type: string
                  enum:
                    - accepted
                    - dismissed
                    - acted
                payload:
                  type: object
                organization_id:
                  type: string
                  format: uuid
                business_slug:
                  type: string
      responses:
        '200':
          description: The updated Action
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HomeAction'
        '400':
          description: Unknown status
        '401':
          description: Not authenticated
        '404':
          description: Action not found in this organization
components:
  parameters:
    OrgId:
      name: organization_id
      in: query
      required: true
      schema:
        type: string
        format: uuid
      description: >-
        Your organization UUID. Workspace endpoints are org-scoped — supply this
        as a query param (writes also accept it in the body). Find it via GET
        /auth/me/ → organizations[].id.
  schemas:
    HomeAction:
      type: object
      description: >
        One Home Action. Identical item shape to GET
        /automation/recommendations/. `summary` is an alias of `why`. First-run
        rows have opportunity=null.
      properties:
        id:
          type: string
          format: uuid
        title:
          type: string
        why:
          type: string
        summary:
          type: string
        effect:
          type: string
          enum:
            - suggest_accept
            - approve_only
            - send
            - publish
            - schedule
        action_label:
          type: string
        effect_note:
          type: string
        is_external:
          type: boolean
        status:
          type: string
          enum:
            - pending
            - viewed
            - acted
            - dismissed
        payload:
          type: object
        related_type:
          type: string
          nullable: true
        related_id:
          type: string
          nullable: true
        source_mode:
          type: string
        created_at:
          type: string
          format: date-time
        type:
          type: string
        actions:
          type: array
          items:
            type: object
        editable:
          type: boolean
        opportunity:
          type: object
          nullable: true
        artifacts:
          type: array
          items:
            type: object
  securitySchemes:
    TokenAuth:
      type: apiKey
      in: header
      name: Authorization
      description: 'DRF user token. Format: `Token <token>`'

````