Skip to main content
Retrieves detailed log information for a specific endpoint execution using the Rapida API.
For more authentication options, see: https://doc.rapida.ai/api-reference/authentication

Parameters

connectionConfig
ConnectionConfig
required
Configuration for the client connection.
request
GetEndpointLogRequest
required

Usage

from rapida import (
    ConnectionConfig,
    GetEndpointLogRequest,
    get_endpoint_log
)
from pprint import pprint
connection_config = ConnectionConfig.default_connection_config(
    ConnectionConfig.with_sdk("{your-rapida-api-key}")
)
response = get_endpoint_log(
    client_cfg=connection_config,
    request=GetEndpointLogRequest(
        id=2230958607199895552,
        endpointId=2223006263292198912,
    ),
)
pprint(response)
package main

import (
	"context"
	"fmt"
	"os"

	clients "github.com/rapidaai/rapida-go/rapida/clients"
	rapida_proto "github.com/rapidaai/rapida-go/rapida/clients/protos"
	connections "github.com/rapidaai/rapida-go/rapida/connections"
)

func main() {
	// Configure client connection using RAPIDA_PROJECT_CREDENTIAL environment variable
	connectionConfig := connections.
		DefaultconnectionConfig(connections.WithSDK(os.Getenv("RAPIDA_PROJECT_CREDENTIAL"))).WithLocal()

	// Retrieve endpoint log by endpoint ID and log ID
	response, err := clients.GetEndpointLog(context.Background(), connectionConfig, &rapida_proto.GetEndpointLogRequest{
		EndpointId: "ENDPOINT_ID",
		Id:         "ENDPOINT_LOG_ID",
	})

	if err != nil {
		fmt.Printf("Error while making call using rapida: %+v\n", err)
		return
	}

	// Print the response
	fmt.Printf("Rapida calling response: %+v\n", response)
}
import {
  ConnectionConfig,
  GetEndpointLog,
  GetEndpointLogRequest,
} from "@rapidaai/nodejs";

(async () => {
  const connectionCfg = ConnectionConfig.DefaultConnectionConfig(
    ConnectionConfig.WithSDK({
      ApiKey: process.env.RAPIDA_PROJECT_CREDENTIAL,
    })
  );
  getEndpointLog(connectionCfg)
})();

async function getEndpointLog(connectionCfg) {
  const request = new GetEndpointLogRequest();
  request.setId(2223006263292198912);
  request.setEndpointid(2223006263292198912);
  const response = await GetEndpointLog(connectionCfg, request);

  if (response.getError()) {
    console.error(
      "Error fetching endpoint log:",
      response.getError()?.getHumanmessage()
    );
  } else {
    console.log("Endpoint Log Details:", response.getData());
  }
}

Response

code
int32
Numeric status code for the operation.
success
boolean
Indicates whether the operation was successful.
data
EndpointLog
Detailed log information for the endpoint execution.
error
object
Error information, if applicable.