# ตั้งงาน Google Finance Markets SERP

**API:** Data API

**Endpoint:** `POST /v1/beta/dataforseo/serp/google/finance_markets/task_post`

**Tags:** DataForSEO

เข้าคิวดัชนีตลาดและหุ้นที่มีการเคลื่อนไหวเด่นที่ Google Finance แสดงบน Google และคืน `id` ของงานใน `tasks[0].id` ห่อด้วย envelope ของ DataForSEO: ข้อมูลอยู่ใน `tasks[0].result` ผลลัพธ์อยู่ใน `tasks[0].status_code` — คำขอที่ถูกปฏิเสธยังคงคืน HTTP 200 endpoint แบบเรียลไทม์คู่กันตอบทันทีและง่ายกว่าสำหรับคำขอเดียว ให้เข้าคิวเมื่อชุดงานใช้เวลานานเกินกว่าการเรียกเครื่องมือหนึ่งครั้ง

### ข้อมูลอ้างอิงราคา

- การวัดปริมาณการใช้งาน: ต้นทุนการตอบกลับที่รายงาน
- ค่าประมาณคำขออ้างอิง: USD 0.02
- ตัวคูณอ้างอิงสำหรับลูกค้า: 1.0 ห้ามนำไปใช้ซ้ำกับยอดที่เรียกเก็บจากลูกค้าแล้ว

เป็นข้อมูลเมตาอ้างอิงเท่านั้น ไม่ใช่ใบเสนอราคาสำหรับบัญชี ไม่ใช่ราคาที่รับประกัน และไม่ใช่เพดานการใช้จ่าย เครดิตของทรัพยากรไม่ใช่เครดิต Felo ยอดเรียกเก็บขั้นสุดท้ายเป็นไปตามบันทึกการเรียกเก็บเงินของ Felo

## Related links

- [Help Center](<https://dataforseo.com/help-center/pingbacks-postbacks-with-dataforseo-api>)
- [ราคา](<https://dataforseo.com/pricing/serp/google-finance-serp-api>)

## Base URL

- `https://openapi.felo.ai`

## Authentication

- `FeloBearerAuth` (http bearer, bearer format Felo API Key)
- `FeloApiKey` (apiKey in header `X-API-Key`)

## Request body

Required: **no**

### application/json

Schema:

```json
{
  "type": "array",
  "items": {
    "type": [
      "object",
      "null"
    ],
    "oneOf": [
      {
        "type": "object",
        "properties": {
          "location_code": {
            "type": "integer",
            "description": "<p><em>รหัสสถานที่ของเครื่องมือค้นหา</em><p><strong>ฟิลด์ที่จำเป็นหากไม่ได้ระบุ <code>location_name</code></strong><p><strong>หากใช้ฟิลด์นี้ ไม่จำเป็นต้องระบุ <code>location_name</code></strong><p>คุณสามารถรับรายการสถานที่ของเครื่องมือค้นหาที่ใช้ได้พร้อม <code>location_code</code> ได้โดยส่งคำขอแยกไปที่ <code>https://api.dataforseo.com/v3/serp/google/locations</code><p>ตัวอย่าง:<p><code class=\"long-string\">2840</code></p>"
          },
          "language_code": {
            "type": "string",
            "description": "<p><em>รหัสภาษาของเครื่องมือค้นหา</em><p><strong>ฟิลด์ที่จำเป็นหากไม่ได้ระบุ <code>language_name</code></strong><p><strong>หากใช้ฟิลด์นี้ ไม่จำเป็นต้องระบุ <code>language_name</code></strong><p>คุณสามารถรับรายการภาษาของเครื่องมือค้นหาที่ใช้ได้พร้อม <code>language_code</code>&nbsp;ได้โดยส่งคำขอแยกไปที่ <code>https://api.dataforseo.com/v3/serp/google/languages</code><em><p></em>ตัวอย่าง:<em><p></em><code class=\"long-string\">en</code></p>"
          },
          "device": {
            "type": [
              "string",
              "null"
            ],
            "description": "<p><em>ประเภทอุปกรณ์</em><p>ฟิลด์ที่ไม่บังคับ<p>คืนผลลัพธ์สำหรับประเภทอุปกรณ์ที่ระบุ<p>ค่าที่เป็นไปได้: <code>desktop</code></p>"
          },
          "pingback_url": {
            "type": [
              "string",
              "null"
            ],
            "description": "<p><em>URL แจ้งเตือนเมื่องานเสร็จสิ้น</em><p>ฟิลด์ที่ไม่บังคับ<p>เมื่องานเสร็จสิ้น เราจะแจ้งให้คุณทราบผ่านคำขอ GET ที่ส่งไปยัง URL ที่คุณระบุ<p>คุณสามารถใช้สตริง ‘$id’ เป็นตัวแปร <code>$id</code> และ ‘$tag’ เป็นตัวแปร <code>$tag</code> แบบ urlencoded เราจะกำหนดค่าที่จำเป็นก่อนส่งคำขอ<p>ตัวอย่าง:<p><code>http://your-server.com/pingscript?id=$id</code><p><code>http://your-server.com/pingscript?id=$id&amp;tag=$tag</code><p><strong>หมายเหตุ:</strong> อักขระพิเศษใน <code>pingback_url</code> จะถูก urlencoded;<p>กล่าวคือ อักขระ <code>#</code> จะถูกเข้ารหัสเป็น <code>%23</code></p><br><p>อ่านเพิ่มเติมได้ที่Help Center ของเรา</p>"
          },
          "postback_url": {
            "type": [
              "string",
              "null"
            ],
            "description": "<p><em>URL สำหรับส่งผลลัพธ์ของงาน</em><p>ฟิลด์ที่ไม่บังคับ<p>เมื่องานเสร็จสิ้น เราจะส่งคำขอ POST พร้อมผลลัพธ์ที่บีบอัดในรูปแบบ <code>gzip</code> ไปยัง <code>postback_url</code> ที่คุณระบุ<p>ใช้สตริง ‘$id’ เป็นตัวแปร <code>$id</code> และ ‘$tag’ เป็นตัวแปร <code>$tag</code> แบบ urlencoded เราจะกำหนดค่าที่จำเป็นก่อนส่งคำขอ<p>ตัวอย่าง:<p><code>http://your-server.com/postbackscript?id=$id</code><p><code>http://your-server.com/postbackscript?id=$id&amp;tag=$tag</code><p><strong>หมายเหตุ:</strong> อักขระพิเศษใน <code>postback_url</code> จะถูก urlencode;<p>กล่าวคือ อักขระ <code>#</code> จะถูกเข้ารหัสเป็น <code>%23</code></p><br><p>อ่านเพิ่มเติมได้ที่Help Center ของเรา</p>"
          },
          "postback_data": {
            "type": "string",
            "description": "<p><em>ชนิดข้อมูลของ postback_url</em><p><strong>ฟิลด์ที่จำเป็นหากระบุ <code>postback_url</code></strong><p>ตรงกับชนิดข้อมูลที่จะส่งไปยังเซิร์ฟเวอร์ของคุณ<p>ค่าที่เป็นไปได้: <code>advanced</code>, <code>html</code></p>"
          },
          "priority": {
            "type": [
              "integer",
              "null"
            ],
            "description": "<p><em>ลำดับความสำคัญของงาน</em><p>ฟิลด์ที่ไม่บังคับ<p>รับค่าต่อไปนี้ได้:<p>1 – ลำดับความสำคัญการทำงานปกติ (กำหนดเป็นค่าเริ่มต้น);<p>2 – ลำดับความสำคัญการทำงานสูง</p><br>งานที่มีลำดับความสำคัญการทำงานสูงจะถูกเรียกเก็บเงินเพิ่ม;<p>ค่าใช้จ่ายสามารถคำนวณได้ที่หน้าราคา"
          },
          "location_name": {
            "type": "string",
            "description": "<p><em>ชื่อเต็มของสถานที่ของเครื่องมือค้นหา</em><p><strong>ฟิลด์ที่จำเป็นหากไม่ได้ระบุ <code>location_code</code></strong><p><strong>หากใช้ฟิลด์นี้ ไม่จำเป็นต้องระบุ <code>location_code</code></strong><p>คุณสามารถรับรายการสถานที่ของเครื่องมือค้นหาที่ใช้ได้พร้อม <code>location_name</code> ได้โดยส่งคำขอแยกไปที่  <code>https://api.dataforseo.com/v3/serp/google/locations</code><p>ตัวอย่าง:<p><code class=\"long-string\">London,England,United Kingdom</code></p>"
          },
          "language_name": {
            "type": "string",
            "description": "<p><em>ชื่อเต็มของภาษาของเครื่องมือค้นหา</em><p><strong>ฟิลด์ที่จำเป็นหากไม่ได้ระบุ <code>language_code</code> </strong><p><strong>หากใช้ฟิลด์นี้ ไม่จำเป็นต้องระบุ <code>language_code</code></strong><p>คุณสามารถรับรายการภาษาของเครื่องมือค้นหาที่ใช้ได้พร้อม <code>language_name</code> ได้โดยส่งคำขอแยกไปที่ <code>https://api.dataforseo.com/v3/serp/google/languages</code><p>ตัวอย่าง:<p><code class=\"long-string\">English</code></p>"
          },
          "os": {
            "type": [
              "string",
              "null"
            ],
            "description": "<p><em>ระบบปฏิบัติการของอุปกรณ์</em><p>ฟิลด์ที่ไม่บังคับ<p>ค่าที่เป็นไปได้: <code>windows</code></p>"
          },
          "tag": {
            "type": [
              "string",
              "null"
            ],
            "description": "<p><em>ตัวระบุงานที่ผู้ใช้กำหนด</em><p>ฟิลด์ที่ไม่บังคับ<p><em>จำกัดอักขระ 255 ตัว</em><p>คุณสามารถใช้พารามิเตอร์นี้เพื่อระบุงานและจับคู่กับผลลัพธ์<p>คุณจะพบค่า <code>tag</code> ที่ระบุในออบเจกต์ <code>data</code> ของการตอบกลับ"
          },
          "market_type": {
            "type": [
              "string",
              "null"
            ],
            "description": "<p><em>ประเภทตลาด Google Finance</em><p>ฟิลด์ที่ไม่บังคับ<p>ค่าที่เป็นไปได้: <code>most-active</code>, <code>indexes</code>, <code>indexes/americas</code>, <code>indexes/europe-middle-east-africa</code>, <code>indexes/asia-pacific</code>, <code>gainers</code>, <code>losers</code>, <code>climate-leaders</code>, <code>cryptocurrencies</code>, <code>currencies</code><p>ค่าเริ่มต้น: <code>most-active</code></p>"
          }
        },
        "example": [
          {
            "location_code": 2840,
            "language_name": "English"
          }
        ]
      }
    ]
  },
  "example": [
    {
      "location_code": 2840,
      "language_name": "English"
    }
  ]
}
```

## Responses

### 200 — ดำเนินการสำเร็จ

Headers:
- `X-Request-Id` (string) — ตัวระบุคำขอที่ต้องระบุเมื่อติดต่อฝ่ายสนับสนุนของ Felo

**application/json**

Schema: object | null

```json
{
  "type": [
    "object",
    "null"
  ],
  "oneOf": [
    {
      "$ref": "#/components/schemas/Response36Afe1097B20_SerpGoogleFinanceMarketsTaskPostResponseInfo"
    }
  ]
}
```

### 400 — ไม่สามารถประมวลผลคำขอได้ ตรวจสอบพารามิเตอร์ของคำขอ

### 401 — จำเป็นต้องใช้คีย์ API ของ Felo ที่ถูกต้อง

### 402 — ไม่สามารถดำเนินการตามคำขอได้ เนื่องจากไม่เป็นไปตามข้อกำหนดด้านการเรียกเก็บเงิน

### 403 — บัญชีไม่ได้รับอนุญาตให้ดำเนินการนี้

### 429 — ถึงขีดจำกัดคำขอหรือการใช้จ่ายแล้ว

### 502 — บริการไม่สามารถดำเนินการตามคำขอให้เสร็จสิ้นได้

### 503 — API หรือบริการเรียกเก็บเงินไม่พร้อมใช้งานชั่วคราว

### 504 — บริการหมดเวลาระหว่างประมวลผลคำขอ

### default — การตอบกลับข้อผิดพลาด; การตอบกลับที่ส่งผ่านจากต้นทางอาจใช้รูปแบบของผู้ให้บริการ

**application/json**

Schema:

```json
{}
```

## Schema definitions

### Response36Afe1097B20_BaseResponseInfo

`#/components/schemas/Response36Afe1097B20_BaseResponseInfo`

```json
{
  "properties": {
    "version": {
      "type": [
        "string",
        "null"
      ],
      "description": "เวอร์ชันปัจจุบันของ API"
    },
    "status_code": {
      "type": [
        "integer",
        "null"
      ],
      "description": "รหัสสถานะทั่วไป\nคุณสามารถดูรายการรหัสการตอบกลับทั้งหมดได้ที่นี่"
    },
    "status_message": {
      "type": [
        "string",
        "null"
      ],
      "description": "ข้อความข้อมูลทั่วไป\nคุณสามารถดูรายการข้อความข้อมูลทั่วไปทั้งหมดได้ที่นี่"
    },
    "time": {
      "type": [
        "string",
        "null"
      ],
      "description": "เวลาดำเนินการทั้งหมด (วินาที)"
    },
    "cost": {
      "type": [
        "number",
        "null"
      ],
      "description": "ค่าใช้จ่ายรวมของงาน, USD",
      "format": "double"
    },
    "tasks_count": {
      "type": [
        "integer",
        "null"
      ],
      "description": "จำนวนงานในอาร์เรย์ tasks",
      "format": "int64"
    },
    "tasks_error": {
      "type": [
        "integer",
        "null"
      ],
      "description": "จำนวนงานในอาร์เรย์ tasks ที่ส่งคืนพร้อมข้อผิดพลาด",
      "format": "int64"
    }
  }
}
```

### Response36Afe1097B20_BaseResponseTaskInfo

`#/components/schemas/Response36Afe1097B20_BaseResponseTaskInfo`

```json
{
  "properties": {
    "id": {
      "type": [
        "string",
        "null"
      ],
      "description": "ตัวระบุงาน\nตัวระบุงานที่ไม่ซ้ำกันในระบบของเราในรูปแบบ UUID"
    },
    "status_code": {
      "type": [
        "integer",
        "null"
      ],
      "description": "รหัสสถานะของงาน\nสร้างโดย DataForSEO โดยอยู่ในช่วงต่อไปนี้ได้: 10000-60000\nคุณสามารถดูรายการรหัสการตอบกลับทั้งหมดได้ที่นี่"
    },
    "status_message": {
      "type": [
        "string",
        "null"
      ],
      "description": "ข้อความข้อมูลของงาน\nคุณสามารถดูรายการข้อความข้อมูลทั่วไปทั้งหมดได้ที่นี่"
    },
    "time": {
      "type": [
        "string",
        "null"
      ],
      "description": "เวลาดำเนินการ, วินาที"
    },
    "cost": {
      "type": [
        "number",
        "null"
      ],
      "description": "ค่าใช้จ่ายรวมของงาน, USD",
      "format": "double"
    },
    "result_count": {
      "type": [
        "integer",
        "null"
      ],
      "description": "จำนวนองค์ประกอบในอาร์เรย์ result",
      "format": "int64"
    },
    "path": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "type": [
          "string",
          "null"
        ]
      },
      "description": "พาธ URL"
    },
    "data": {
      "type": [
        "object",
        "null"
      ],
      "additionalProperties": {
        "type": [
          "object",
          "null"
        ]
      },
      "description": "มีพารามิเตอร์เดียวกับที่คุณระบุในคำขอ POST"
    }
  }
}
```

### Response36Afe1097B20_SerpGoogleFinanceMarketsTaskPostResponseInfo

`#/components/schemas/Response36Afe1097B20_SerpGoogleFinanceMarketsTaskPostResponseInfo`

```json
{
  "type": "object",
  "allOf": [
    {
      "$ref": "#/components/schemas/Response36Afe1097B20_BaseResponseInfo"
    },
    {
      "type": "object",
      "properties": {
        "tasks": {
          "type": [
            "array",
            "null"
          ],
          "items": {
            "type": [
              "object",
              "null"
            ],
            "oneOf": [
              {
                "$ref": "#/components/schemas/Response36Afe1097B20_SerpGoogleFinanceMarketsTaskPostTaskInfo"
              }
            ]
          },
          "description": "<em>อาร์เรย์ของงาน</em>"
        }
      }
    }
  ]
}
```

### Response36Afe1097B20_SerpGoogleFinanceMarketsTaskPostTaskInfo

`#/components/schemas/Response36Afe1097B20_SerpGoogleFinanceMarketsTaskPostTaskInfo`

```json
{
  "type": "object",
  "allOf": [
    {
      "$ref": "#/components/schemas/Response36Afe1097B20_BaseResponseTaskInfo"
    },
    {
      "type": "object",
      "properties": {
        "result": {
          "type": [
            "object",
            "null"
          ],
          "description": "<em>อาร์เรย์ของผลลัพธ์</em><br>ในกรณีนี้ ค่าจะเป็น <code>null</code>"
        }
      }
    }
  ]
}
```
