ข้ามไปยังเนื้อหา

Namespace Cephalon.Behaviors.Http.Bindings

เนื้อหานี้ยังไม่ได้แปลเป็นภาษาไทย แสดงเป็นภาษาอังกฤษแทน

GraphqlHttpBehaviorBinding

GraphQL HTTP transport binding (transport ID: http.graphql). Accepts canonical routes such as POST /graphql/v1/cart/get. The request body uses a standard GraphQL envelope and the variables object is dispatched as the behavior input.

GraphqlRequest

Represents a parsed GraphQL request containing the query string and optional variables.

GraphqlSseBehaviorBinding

GraphQL over Server-Sent Events (SSE) transport binding (transport ID: http.graphql-sse). Accepts canonical routes such as POST /graphql-sse/v1/cart/get. The variables object is used as the behavior input, then the result is streamed as SSE events before sending a complete event.

GraphqlWsBehaviorBinding

GraphQL over WebSocket transport binding (transport ID: http.graphql-ws). Upgrades canonical routes such as GET /graphql-ws/v1/cart/get to a WebSocket connection. The connection implements the graphql-transport-ws sub-protocol: connection_initconnection_acksubscribenextcomplete.

JsonRpcError

Represents the error object inside a JSON-RPC 2.0 error response.

JsonRpcErrorResponse

Represents an error JSON-RPC 2.0 response envelope.

JsonRpcHttpBehaviorBinding

JSON-RPC 2.0 HTTP transport binding (transport ID: http.jsonrpc). Accepts canonical routes such as POST /json-rpc/v1/cart/get and returns a JSON-RPC 2.0 response or error object. Per the JSON-RPC 2.0 specification the HTTP status is always 200 OK.

JsonRpcRequest

Represents a JSON-RPC 2.0 request envelope.

JsonRpcSuccessResponse

Represents a successful JSON-RPC 2.0 response envelope.

SseBehaviorBinding

Server-Sent Events transport binding (transport ID: http.sse). Opens a long-lived SSE stream at canonical routes such as GET /sse/v1/cart/get. Query-string parameters are parsed into a JSON object and deserialized as the behavior’s typed input. The behavior is dispatched immediately; its return value is streamed as a data: {json}\n\n event. The connection stays alive with periodic heartbeat comments until the client disconnects.

WebSocketBehaviorBinding

Bidirectional WebSocket transport binding (transport ID: http.ws). Upgrades canonical routes such as GET /ws/v1/cart/get to a full-duplex WebSocket connection. Each received JSON text frame is dispatched to the behavior and the result is sent back as a JSON text frame. The connection is closed gracefully on client close or cancellation.