GLM

glm/glm-5.2

- context · $0.8400 / M input tokens · $2.6400 / M output tokens

GLM 5.2 OurToken पर GLM model route है, उन developers के लिए जो hosted API access, coding workflows, long-context tasks, pricing और production assistant workloads evaluate कर रहे हैं।

मूल्य निर्धारण

उपयोग के अनुसार भुगतान

कोई अग्रिम लागत नहीं, केवल उतने के लिए भुगतान करें जितना आप उपयोग करते हैं

60% of official price
Input$1.40 / M$0.8400 / M Tokens
Output$4.40 / M$2.6400 / M Tokens

API उपयोग

API Access Guide

Base URLhttps://api.ourtoken.ai/v1
API Endpointchat/completions
Full URLhttps://api.ourtoken.ai/v1/chat/completions
Model IDglm-5.2
API Key प्राप्त करें

कोड उदाहरण

इस मॉडल के लिए OurToken API endpoint का उपयोग करें। नीचे दिए गए उदाहरण direct HTTP requests और मॉडल परिवार के लिए recommended endpoint का उपयोग करते हैं।

curl https://api.ourtoken.ai/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "model": "glm-5.2",
    "messages": [
      {
        "role": "user",
        "content": "Hello!"
      }
    ],
    "max_tokens": 256
  }'

Chat Completions API संदर्भ

OpenAI Chat Completions-संगत endpoint के साथ chat response बनाएँ। SDK Base URL के रूप में https://api.ourtoken.ai/v1 और endpoint के रूप में POST /chat/completions का उपयोग करें।

Authorization

Content-Typeapplication/json
AuthorizationBearer YOUR_API_KEY

Request Body

फ़ील्डप्रकारआवश्यकविवरण
modelstringआवश्यककॉल करने के लिए Model ID।
messagesarray<object>आवश्यकmodel को भेजे गए conversation messages।
max_tokensintegerवैकल्पिकoutput tokens की अधिकतम संख्या।
temperaturenumberवैकल्पिकSampling temperature।
top_pnumberवैकल्पिकNucleus sampling parameter।
streambooleanवैकल्पिकक्या streaming response लौटाना है।
stream_optionsobjectवैकल्पिकstreaming responses के लिए अतिरिक्त options।
toolsarray<object>वैकल्पिकmodel के लिए उपलब्ध tools।
tool_choicestring | objectवैकल्पिकmodel tools कैसे चुनता है, इसे नियंत्रित करता है।
response_formatobjectवैकल्पिकstructured output को नियंत्रित करता है, जैसे JSON object responses।

Response Body

फ़ील्डप्रकारआवश्यकविवरण
idstringआवश्यकunique chat completion identifier।
object"chat.completion"आवश्यकChat Completions API द्वारा लौटाया गया object type।
createdintegerआवश्यकresponse बनाए जाने का Unix timestamp।
modelstringआवश्यकवह model जिसने response बनाया।
choicesarray<object>आवश्यकmodel द्वारा लौटाए गए candidate responses।
choices[].message.rolestringआवश्यकलौटाए गए chat message की role।
choices[].message.contentstringवैकल्पिकलौटाए गए chat message में text content।
choices[].finish_reasonstringवैकल्पिकgeneration रुकने का कारण।
usageobjectवैकल्पिकchat completion के लिए token usage information।
usage.prompt_tokensintegerवैकल्पिकInput token count।
usage.completion_tokensintegerवैकल्पिकOutput token count।
usage.total_tokensintegerवैकल्पिकTotal token count।
usage.prompt_tokens_detailsobjectवैकल्पिकinput token usage का breakdown।
usage.prompt_tokens_details.cached_tokensintegerवैकल्पिकcache से served tokens।

मॉडल परिचय

GLM glm-5.2

GLM 5.2 OurToken पर GLM model route है, उन developers के लिए जो hosted API access, coding workflows, long-context tasks, pricing और production assistant workloads evaluate कर रहे हैं।

Supplied launch material के अनुसार GLM 5.2, GLM 5.1 line पर build करता है और coding capability, long-horizon work तथा 1M-context evaluation पर focused है। जब आपको model testing, pricing review, API keys, usage logs और production integration के लिए एक endpoint चाहिए हो, तब OurToken के माध्यम से glm 5.2 api उपयोग करें।

यह बेहतरीन क्यों है

  • Input, output और cache read tokens के लिए official GLM 5.2 reference price का 60%।
  • अन्य supported models द्वारा उपयोग किए जाने वाले उसी OurToken endpoint के माध्यम से OpenAI-compatible API setup।
  • GLM coding, agent workflows, long-context sessions और OpenCode-style development tasks evaluate करने के लिए उपयोगी।
  • Supplied launch material 1M-context support और GLM Coding Plan availability बताता है, जबकि independent benchmark coverage अलग से review की जानी चाहिए।
  • Dashboard logs और usage visibility launch के बाद request cost compare करने में teams की मदद करते हैं।

मुख्य विशेषताएँ

  • Model ID: glm-5.2
  • Input price: OurToken पर $0.8400 per 1M tokens
  • Output price: OurToken पर $2.6400 per 1M tokens
  • Cache read price: OurToken पर $0.1560 per 1M tokens
  • Cache write price: OurToken पर $0 per 1M tokens
  • Provider: GLM

विशिष्टताएँ

ProviderGLM
Model TypeLarge Language Model (LLM)
Model IDglm-5.2
OurToken Input Price$0.8400 / 1M tokens
OurToken Output Price$2.6400 / 1M tokens
OurToken Cache Read Price$0.1560 / 1M tokens
OurToken Cache Write Price$0 / 1M tokens
Official Input Reference$1.40 / 1M tokens
Official Output Reference$4.40 / 1M tokens
Official Cache Read Reference$0.26 / 1M tokens

Developers के लिए glm 5.2 api Features

Unified GLM access, glm 5.2 pricing visibility, coding evaluation, long-context planning और production workflow testing के लिए glm 5.2 api उपयोग करें।

Unified Access

Separate GLM provider integration बनाने के बजाय OurToken unified endpoint के माध्यम से glm 5.2 api call करें। Developers एक API key create कर सकते हैं, glm-5.2 को model ID के रूप में उपयोग कर सकते हैं, और testing तथा production में OpenAI-compatible request patterns रख सकते हैं।

Pricing Visibility

Traffic route करने से पहले glm 5.2 pricing review करें। OurToken $0.8400 input, $2.6400 output और $0.1560 cache read per 1M tokens list करता है, cache write $0 है, जिससे prompt और agent workload costs estimate किए जा सकते हैं।

Coding Workflows

Repository tasks, coding agents, tool-use loops और planning-heavy development prompts पर GLM 5.2 model behavior evaluate करें। Supplied launch material model को long-horizon coding के लिए position करता है, लेकिन teams को quality अपने acceptance tests से confirm करनी चाहिए।

Benchmark Context

glm 5.2 benchmark searches को discovery signals के रूप में उपयोग करें, final procurement proof के रूप में नहीं। User-supplied notes में Pac-Man और coding-plan evaluations हैं, जबकि launch coverage कहती है कि independent benchmark results को third-party verification की जरूरत हो सकती है।

OpenCode Testing

OurToken के माध्यम से realistic multi-step coding prompts भेजकर opencode glm 5.2 workflows test करें और tool behavior, latency, token usage तथा output quality review करें। Comparison runs में prompts, model ID और budget assumptions consistent रखें।

Provider Comparison

Provider choice evaluate करते समय hosted OurToken access की तुलना glm 5.2 openrouter जैसी searches से करें। OurToken API keys, usage logs, pricing visibility और unified endpoint पर focused है, separate provider-specific setup पर नहीं।

OurToken पर glm 5.2 api कैसे उपयोग करें

API key बनाएं, glm-5.2 copy करें, glm 5.2 pricing compare करें, unified endpoint call करें और coding workflows test करें।

Create API Key

Dashboard से OurToken API key create करें और उसे secure server-side environment variable में store करें। इससे आपका backend glm 5.2 api access कर सकता है, credentials को browser code, notebooks या public repositories में expose किए बिना।

01

Copy Model ID

Request body में model value के रूप में glm-5.2 उपयोग करें। Exact GLM 5.2 model ID को configuration में रखने से local tests, staging traffic और production routes compare करते समय naming mistakes से बचा जा सकता है।

02

Call Endpoint

अपनी API key, model ID और prompt payload के साथ OurToken unified API endpoint पर chat completions requests भेजें। Base URL, credential और model value बदलने के बाद existing OpenAI-compatible request patterns आमतौर पर reuse किए जा सकते हैं।

03

Compare Pricing

Traffic scale करने से पहले glm 5.2 pricing compare करें: OurToken $0.8400 input, $2.6400 output और $0.1560 cache read per 1M tokens list करता है। Cache write $0 listed है, इसलिए cached prompts को normal input और output से अलग रखें।

04

Test Coding

Repository tasks, one-shot application builds, OpenCode-style agent sessions और regression prompts के साथ अपना glm 5.2 coding plan चलाएं। Public anecdotes test cases inspire कर सकते हैं, लेकिन production routing आपके latency, quality और cost data पर depend करना चाहिए।

05

Monitor Usage

Launch के बाद history logs में request counts, input tokens, output tokens, cache read tokens और spend review करें। इससे teams GLM 5.2 model performance को benchmark posts या provider listings के बजाय actual traffic से compare कर सकती हैं।

06

glm 5.2 api FAQ

glm 5.2 api access, glm-5.2 model ID, pricing, benchmark interpretation, OpenCode testing और OpenRouter comparisons के उत्तर।

01

glm 5.2 api क्या है?

glm 5.2 api OurToken के माध्यम से उपलब्ध GLM 5.2 model route है, उन developers के लिए जो GLM coding, chat, long-context और agent-style workflows तक hosted access चाहते हैं। OurToken API key के साथ glm-5.2 model ID उपयोग करें और इसे unified API flow से call करें।
02

OurToken पर glm 5.2 pricing क्या है?

OurToken पर glm 5.2 pricing $0.8400 per 1M input tokens और $2.6400 per 1M output tokens है। Catalog cache read को $0.1560 per 1M tokens और cache write को $0 list करता है, official references $1.40 input, $4.40 output और $0.26 cache read हैं।
03

GLM 5.2 के लिए कौन सा model ID उपयोग करना चाहिए?

API requests में exact model value के रूप में glm-5.2 उपयोग करें। Development, staging और production में model ID unchanged रखने से teams जब GLM 5.2 model behavior, pricing, latency और coding quality compare करती हैं, तब route mismatches से बचती हैं।
04

क्या official glm 5.2 benchmark उपलब्ध है?

User-supplied launch coverage कहती है कि independent benchmark results launch पर published नहीं थे, जबकि community tests में one-shot Pac-Man और coding workflow experiments शामिल हैं। glm 5.2 benchmark material को evaluation input मानें, फिर production default चुनने से पहले अपनी tasks run करें।
05

क्या मैं OurToken से opencode glm 5.2 workflows test कर सकता हूं?

हां। आप realistic repository prompts, tool-use tasks और coding-plan sessions के साथ OurToken के माध्यम से glm-5.2 call करके opencode glm 5.2 workflows test कर सकते हैं। Public anecdotes पर ही निर्भर न रहें; output quality, latency, token usage और failure modes को अपने acceptance criteria से compare करें।
06

glm 5.2 openrouter comparison का OurToken से क्या संबंध है?

glm 5.2 openrouter searches आमतौर पर provider comparison intent दिखाती हैं। OurToken model IDs, pricing visibility, usage logs और unified endpoint के साथ hosted API route है। Production workloads migrate करने से पहले availability, latency, price, logging needs और integration effort compare करें।