URSY.DEVPART OF THE URSY NETWORKSign inBuild with URSY

Every contract sourcedEvery check datedGaps shown, never filledBuild with URSY

Endpoints

nicola_ask

Ask this public-service specialist a bounded natural-language question.

POST/askv1.0.0

Request

This operation declares public access.

CURL
curl -X POST 'https://ursy.delivery/wp-json/nicola/v2/ask' \
  -H 'Accept: application/json'
Scopes
None declared
Execution
At the owning service
Risk classification
not declared

Parameters

This operation declares no parameters.

This operation is documented here. Use the owning service with the appropriate credentials and permissions to execute it.

Response schemas and request body
CONTRACT JSON
{
    "requestBody": {
        "required": true,
        "content": {
            "application/json": {
                "schema": {
                    "type": "object",
                    "properties": {
                        "question": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 4000
                        },
                        "constraints": {
                            "type": "object"
                        },
                        "conversation_ref": {
                            "type": [
                                "string",
                                "null"
                            ]
                        },
                        "max_results": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 20
                        }
                    },
                    "required": [
                        "question"
                    ],
                    "additionalProperties": false
                }
            }
        }
    },
    "responses": {
        "200": {
            "description": "Source-owned structured public result",
            "content": {
                "application/json": {
                    "schema": {
                        "type": "object",
                        "required": [
                            "status",
                            "answer",
                            "items"
                        ],
                        "properties": {
                            "request_id": {
                                "type": "string"
                            },
                            "status": {
                                "enum": [
                                    "answered",
                                    "needs_clarification",
                                    "out_of_scope",
                                    "unavailable",
                                    "pending",
                                    "partial",
                                    "no_results"
                                ]
                            },
                            "intent": {
                                "type": "string"
                            },
                            "answer": {
                                "type": "string",
                                "maxLength": 12000
                            },
                            "items": {
                                "type": "array",
                                "maxItems": 100,
                                "items": {
                                    "type": "object"
                                }
                            },
                            "sources": {
                                "type": "array",
                                "items": {
                                    "type": "object"
                                }
                            },
                            "freshness": {
                                "type": "object"
                            },
                            "clarification": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            },
                            "next_actions": {
                                "type": "array",
                                "items": {
                                    "type": "object"
                                }
                            },
                            "conversation_ref": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            }
                        },
                        "additionalProperties": true
                    }
                }
            }
        },
        "default": {
            "description": "Bounded source error",
            "content": {
                "application/json": {
                    "schema": {
                        "type": "object",
                        "required": [
                            "error",
                            "request_id"
                        ],
                        "properties": {
                            "error": {
                                "type": "object",
                                "required": [
                                    "code",
                                    "message",
                                    "retryable"
                                ],
                                "properties": {
                                    "code": {
                                        "type": "string"
                                    },
                                    "message": {
                                        "type": "string"
                                    },
                                    "retryable": {
                                        "type": "boolean"
                                    },
                                    "details": {
                                        "type": "object"
                                    }
                                }
                            },
                            "request_id": {
                                "type": "string"
                            }
                        }
                    }
                }
            }
        }
    }
}