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

# isMessage

***

# Function: isMessage()

```ts theme={null}
function isMessage(
  obj: any,
): obj is {
  content: string;
  role:
    | "function"
    | "agent"
    | "tool"
    | "user"
    | "assistant"
    | "developer"
    | "system";
  tool_call_id?: null | string;
  tool_calls?:
    | null
    | { function: { arguments: string; name: string }; id: string }[];
};
```

Defined in: [src/types/message.types.ts](https://github.com/rungalileo/galileo-js/blob/main/src/types/message.types.ts)

## Parameters

### obj

`any`

## Returns

obj is \{ content: string; role: "function" | "agent" | "tool" | "user" | "assistant" | "developer" | "system"; tool\_call\_id?: null | string; tool\_calls?: null | \{ function: \{ arguments: string; name: string }; id: string }\[] }
