POST · Chercher des rapprochements

Feedback : Chercher des rapprochements. Paramètres, accès et exemples de réponse.

Rédigé par Red Blue

Mis à jour le

Feedback

POST /api/v1/feedback/suggestions

operationId : feedback_suggest

Accès

Permission

Consentements OAuth

OAuth : délégation d’un équipier pour l’API

feedback.read

api:connect, feedback:read

KHONY_ORIGIN est l’origine HTTPS de votre application Khony, sans chemin final. Remplacez les identifiants de l’exemple par ceux de vos ressources autorisées. Les données de réponse ci-dessous illustrent le format ; elles ne sont pas le résultat d’un appel à votre organisation.

Champs du corps JSON

Nom

Emplacement

Requis

Type et contraintes

productId

JSON

Oui

string

query

JSON

Oui

string ; Longueur maximale : 160

excludePostId

JSON

Non

string

Exemple de requête

Shell
curl --request POST "$KHONY_ORIGIN/api/v1/feedback/suggestions" \
  --header "Authorization: Bearer $KHONY_ACCESS_TOKEN" \
  --header 'Content-Type: application/json' \
  --data-raw '{
  "productId": "product_01k3w8d7vhe008000000000001",
  "query": "Add dark mode to the portal"
}'
Shell

Réponse de succès · HTTP 200

JSON
{
  "data": []
}
JSON
Schéma complet du corps JSON
JSON
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "productId": {
      "type": "string",
      "pattern": "^product_[0-7][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
    },
    "query": {
      "type": "string",
      "minLength": 6,
      "maxLength": 160
    },
    "excludePostId": {
      "type": "string",
      "pattern": "^post_[0-7][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
    }
  },
  "required": [
    "productId",
    "query"
  ],
  "additionalProperties": false
}
JSON
Schéma complet de la réponse
JSON
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "data": {
      "$ref": "#/$defs/__schema0"
    }
  },
  "required": [
    "data"
  ],
  "additionalProperties": false,
  "$defs": {
    "__schema0": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "number"
        },
        {
          "type": "boolean"
        },
        {
          "type": "null"
        },
        {
          "type": "array",
          "items": {
            "$ref": "#/$defs/__schema0"
          }
        },
        {
          "type": "object",
          "propertyNames": {
            "type": "string"
          },
          "additionalProperties": {
            "$ref": "#/$defs/__schema0"
          }
        }
      ]
    }
  }
}
JSON

Refus et reprise

Les statuts documentés pour cette opération sont 400, 401, 402, 403, 404, 409, 428, 429, 500, 503. Identifiez la cause avec error.code et, lorsqu’il est présent, error.reason. Une réponse 409 peut demander une relecture de révision ou signaler une commande incompatible ; une réponse 428 demande une confirmation humaine. Ne rejouez une écriture que selon son contrat.

Notes du contrat
JSON
{
  "description": "Dedicated API OAuth api:connect and the stated Feedback scope, actual delegated teammate, current organization/product consent and native role. Existing organization keys do not acquire these operations. Every admission consumes an API request. Reuses lexical and native semantic retrieval, budget/admission, tenant/audience cache and source filters. Query minimum six characters. Candidates are not a probability of duplicate intent. No merge/decision is performed. May incur AI work each call, no replay guarantee. Reauthorizes after retrieval."
}
JSON