---
slug: operating
title: Operating Metrics
sidebar_position: 19
language_tabs: false
toc_footers: []
includes: []
search: true
highlight_theme: ''
headingLevel: 2
---

Get operating metrics and financial indicator summaries by report period.

<CliCommand>
longbridge operating AAPL.US
longbridge operating TSLA.US
</CliCommand>


## SDK

| Language | Link |
|---|---|
| Python | [longbridge.openapi.fundamental._fundamental_context](https://longbridge.github.io/openapi/python/reference_all/#longbridge.openapi.fundamental._fundamental_context) |
| Rust | [longbridge::<SDKLinks module="fundamental" klass="FundamentalContext" method="operating" />::fundamental#_fundamental_context](https://longbridge.github.io/openapi/rust/longbridge/<SDKLinks module="fundamental" klass="FundamentalContext" method="operating" />/struct.fundamental.html#method._fundamental_context) |
| Go | [fundamental.operating](https://pkg.go.dev/github.com/longbridge/openapi-go/<SDKLinks module="fundamental" klass="FundamentalContext" method="operating" />#fundamental.operating) |
| Node.js | [fundamental#FundamentalContext](https://longbridge.github.io/openapi/nodejs/classes/fundamental.html#fundamentalcontext) |
| Java | [fundamental.getFundamentalContext](https://longbridge.github.io/openapi/java/com/longbridge/<SDKLinks module="fundamental" klass="FundamentalContext" method="operating" />/fundamental.html#getFundamentalContext) |
| C++ | [longbridge::<SDKLinks module="fundamental" klass="FundamentalContext" method="operating" />::fundamental::_fundamental_context](https://longbridge.github.io/openapi/cpp/classlongbridge_1_1<SDKLinks module="fundamental" klass="FundamentalContext" method="operating" />_1_1_fundamental.html) |


## Parameters

> **SDK method parameters.**

| Name | Type | Required | Description |
| ---- | ---- | -------- | ----------- |
| symbol | string | YES | Security symbol, e.g. `AAPL.US` |
| period | string | NO | Report period filter, e.g. `q1`, `q2`, `q3`, `q4`, `annual` |

## Request Example

<Tabs groupId="request-example">
  <TabItem value="python" label="Python">

```python
from longbridge.openapi import FundamentalContext, Config, OAuthBuilder

oauth = OAuthBuilder("your-client-id").build(lambda url: print("Visit:", url))
config = Config.from_oauth(oauth)
ctx = FundamentalContext(config)

resp = ctx.operating("AAPL.US")
print(resp)
```

  </TabItem>
  <TabItem value="python-async" label="Python (async)">

```python
import asyncio
from longbridge.openapi import AsyncFundamentalContext, Config, OAuthBuilder

async def main() -> None:
    oauth = await OAuthBuilder("your-client-id").build_async(lambda url: print("Visit:", url))
    config = Config.from_oauth(oauth)
    ctx = AsyncFundamentalContext.create(config)

    resp = await ctx.operating("AAPL.US")
    print(resp)

if __name__ == "__main__":
    asyncio.run(main())
```

  </TabItem>
  <TabItem value="nodejs" label="Node.js">

```javascript
const { Config, FundamentalContext, OAuth } = require('longbridge')

async function main() {
  const oauth = await OAuth.build('your-client-id', (_, url) => {
    console.log('Open this URL to authorize: ' + url)
  })
  const config = Config.fromOAuth(oauth)
  const ctx = FundamentalContext.new(config)
  const resp = await ctx.operating('AAPL.US')
  console.log(resp)
}
main().catch(console.error)
```

  </TabItem>
  <TabItem value="java" label="Java">

```java
import com.longbridge.*;
import com.longbridge.fundamental.*;

class Main {
    public static void main(String[] args) throws Exception {
        try (OAuth oauth = new OAuthBuilder("your-client-id").build(url -> System.out.println("Open to authorize: " + url)).get();
             Config config = Config.fromOAuth(oauth);
             FundamentalContext ctx = FundamentalContext.create(config)) {
            var resp = ctx.getOperating("AAPL.US").get();
            System.out.println(resp);
        }
    }
}
```

  </TabItem>
  <TabItem value="rust" label="Rust">

```rust
use std::sync::Arc;
use longbridge::{oauth::OAuthBuilder, fundamental::FundamentalContext, Config};

#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
    let oauth = OAuthBuilder::new("your-client-id").build(|url| println!("Open: {url}")).await?;
    let config = Arc::new(Config::from_oauth(oauth));
    let ctx = FundamentalContext::new(config);
    let resp = ctx.operating("AAPL.US").await?;
    println!("{:?}", resp);
    Ok(())
}
```

  </TabItem>
  <TabItem value="cpp" label="C++">

```cpp
#include <iostream>
#include <longbridge.hpp>

using namespace longbridge;
using namespace longbridge::fundamental;

int main() {
    OAuthBuilder("your-client-id").build(
        [](const std::string& url) { std::cout << "Open: " << url << std::endl; },
        [](auto res) {
            if (!res) return;
            Config config = Config::from_oauth(*res);
            FundamentalContext ctx = FundamentalContext::create(config);
            ctx.operating("AAPL.US", [](auto resp) {
                if (resp) std::cout << "OK" << std::endl;
            });
        });
    std::cin.get();
}
```

  </TabItem>
  <TabItem value="go" label="Go">

```go
package main

import (
	"context"
	"fmt"
	"log"

	"github.com/longbridge/openapi-go/config"
	"github.com/longbridge/openapi-go/oauth"
	"github.com/longbridge/openapi-go/fundamental"
)

func main() {
	o := oauth.New("your-client-id").
		OnOpenURL(func(url string) { fmt.Println("Open this URL to authorize:", url) })
	if err := o.Build(context.Background()); err != nil {
		log.Fatal(err)
	}
	conf, err := config.New(config.WithOAuthClient(o))
	if err != nil {
		log.Fatal(err)
	}
	c, err := fundamental.NewFromCfg(conf)
	if err != nil {
		log.Fatal(err)
	}
	defer c.Close()
	resp, err := c.Operating(context.Background(), "AAPL.US")
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", resp)
}
```

  </TabItem>
</Tabs>

## Response


### Response Example

```json
{
  "code": 0,
  "message": "success",
  "data": {
    "list": [
      {
        "id": "12345",
        "report": "af",
        "title": "FY2025 Annual Report Summary",
        "txt": "Management discussion...",
        "latest": true,
        "web_url": "https://longbridge.com/wiki/...",
        "financial": {
          "code": "700",
          "currency": "HKD",
          "name": "Tencent",
          "region": "HK",
          "report": "af",
          "indicators": [
            {
              "field_name": "operating_revenue",
              "indicator_name": "Revenue",
              "indicator_value": "6786 亿",
              "yoy": "0.0800"
            }
          ]
        }
      }
    ]
  }
}
```

### Response Status

| Status | Description | Schema |
| ------ | ----------- | ------ |
| 200    | Success     | [OperatingList](#OperatingList) |
| 400    | Bad request | None   |

## Schemas

### OperatingListResponse

<a id="OperatingListResponse"></a>

| Name | Type | Required | Description |
| ---- | ---- | -------- | ----------- |
| list | object[] | true | List of operating summary reports, see [OperatingItem](#OperatingItem) |

### OperatingItem

<a id="OperatingItem"></a>

| Name | Type | Required | Description |
| ---- | ---- | -------- | ----------- |
| id | string | false | Internal report ID |
| report | string | false | Report period code (e.g. `af` = annual) |
| title | string | false | Report title |
| txt | string | false | Management discussion text |
| latest | boolean | false | Whether this is the most recent report |
| web_url | string | false | URL to the full report page |
| financial | object | false | Key financial metrics |

### OperatingFinancial

<a id="OperatingFinancial"></a>

| Name | Type | Required | Description |
| ---- | ---- | -------- | ----------- |
| code | string | false | Ticker code |
| name | string | false | Company name |
| currency | string | false | Reporting currency |
| region | string | false | Market region |
| report | string | false | Report period code |
| indicators | object[] | false | Financial indicators, see [OperatingIndicator](#OperatingIndicator) |

### OperatingIndicator

<a id="OperatingIndicator"></a>

| Name | Type | Required | Description |
| ---- | ---- | -------- | ----------- |
| field_name | string | true | Field name key (e.g. `operating_revenue`) |
| indicator_name | string | false | Display name |
| indicator_value | string | false | Formatted value |
| yoy | string | false | Year-over-year change rate |
