http/https отвечает за шифрование; HTTP/1.1 и HTTP/2 определяют, как в соединении передаются запросы. Это разные вещи. Большинству пользователей следует просто использовать https://api.apiyi.com.
Нет.http:// или https:// определяет, зашифрован ли трафик. HTTP/1.1 или HTTP/2 — это версия протокола, которая определяет, как запросы передаются по соединению. Возможна любая их комбинация.Почти всем пользователям следует просто использовать этот адрес и ничего не менять:
HTTP/1.1: один запрос за раз на соединение, поэтому параллельные запросы означают больше соединений HTTP/2: множество запросов используют одно соединение (мультиплексирование)
Версия протокола согласовывается между клиентом и сервером при установке соединения. Она не определяется тем, как записан URL. Эндпоинт https:// APIYI поддерживает как HTTP/1.1, так и HTTP/2 и использует тот протокол, который поддерживает ваш клиент.Поэтому распространенное мнение о том, что «http означает HTTP/1.1, а https означает HTTP/2», является заблуждением:
Для адресов http:// популярные клиенты практически всегда используют HTTP/1.1, но это лишь совпадение результата
Для адресов https:// некоторые клиенты используют HTTP/1.1, а другие — HTTP/2, в зависимости от самого клиента
Конечные пользователи: используйте https и ничего не меняйте
Физические лица и компании, вызывающие API напрямую, должны использовать https://api.apiyi.com. Стандартные SDK для Python, Node и других языков отлично работают по умолчанию, без необходимости настройки протокола.
2
Клиенты на Go / Java с большим количеством параллельных запросов на загрузку изображений: оставьте https, отключите HTTP/2 в клиенте
HTTP/2 объединяет множество параллельных запросов в одном соединении. При загрузке изображений размером в несколько МБ любая заминка в этом соединении замедляет каждый проходящий по нему запрос. Если ваш клиент по умолчанию использует HTTP/2 и вы выполняете генерацию или редактирование изображений с большим количеством параллельных запросов, переключите клиент на HTTP/1.1. Сохраняйте адрес https; переходить на http не требуется.
3
http://api.apiyi.com:16888: только как резервный вариант
Это официально предоставляемый незашифрованный эндпоинт. Используйте его только в качестве временного решения, когда само рукопожатие HTTPS завершается ошибкой (например, Python выдаёт SSLEOFError, но curl работает?), либо внутри доверенной внутренней сети или выделенной линии связи.
http:// не зашифрован. Ваш ключ API, prompts и изображения передаются по публичной сети в виде открытого текста и видны любому сетевому устройству на пути следования. Не полагайтесь на незашифрованный эндпоинт как на долгосрочное решение для продакшена.
Для клиентов, которые уже используют HTTP/1.1, таких как Python и Node, переход на http экономит всего одно рукопожатие TLS (долю секунды). Это ничтожно мало по сравнению со временем генерации изображений в десятки секунд, и при этом вы теряете шифрование.
Нужно ли переходить на http://, чтобы отключить HTTP/2?
Нет. HTTP/2 отключается на стороне клиента; см. пример для Go выше. В других языках есть аналогичные параметры. После этого продолжайте использовать https://api.apiyi.com, и вы получите HTTP/1.1 с шифрованием.
HTTP/2 — это плохо?
Нет. Для браузеров и обычных текстовых чатов, где запросы небольшие и многочисленные, повторное использование соединений в HTTP/2 экономит ресурсы. Единое мультиплексированное соединение становится узким местом только тогда, когда большое количество параллельных запросов сочетается с большими телами запросов или ответов.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"API易文档中心","description":"企业级专业稳定的AI大模型API中转站,一个令牌、无限模型。支持OpenAI、Claude、Gemini、DeepSeek、Qwen等 200+ 精选 AI 模型。","colors":{"primary":"#2563eb","light":"#3b82f6","dark":"#1d4ed8"},"logo":{"light":"https://mintcdn.com/apiyillc/LjCT1O0GrSur6F2v/logo/light.svg?fit=max\u0026auto=format\u0026n=LjCT1O0GrSur6F2v\u0026q=85\u0026s=4119ef17a74cc54be127f34578d8b5fa","dark":"https://mintcdn.com/apiyillc/LjCT1O0GrSur6F2v/logo/dark.svg?fit=max\u0026auto=format\u0026n=LjCT1O0GrSur6F2v\u0026q=85\u0026s=1f046ae9580247d96549ade642b5ecc4"},"favicon":"https://mintcdn.com/apiyillc/OMY6ItCc2mC1yzgA/logo/logo.webp?fit=max\u0026auto=format\u0026n=OMY6ItCc2mC1yzgA\u0026q=85\u0026s=62a7977ef801070e689df2d0291b9d13","api":{"openapi":["api-reference/nano-banana-2-generate-openapi.yaml","api-reference/nano-banana-2-edit-openapi.yaml","api-reference/nano-banana-2-generate-openapi-en.yaml","api-reference/nano-banana-2-edit-openapi-en.yaml","api-reference/nano-banana-pro-generate-openapi.yaml","api-reference/nano-banana-pro-edit-openapi.yaml","api-reference/nano-banana-pro-generate-openapi-en.yaml","api-reference/nano-banana-pro-edit-openapi-en.yaml","api-reference/gpt-image-2-all-generate-openapi.yaml","api-reference/gpt-image-2-all-edit-openapi.yaml","api-reference/gpt-image-2-all-generate-openapi-en.yaml","api-reference/gpt-image-2-all-edit-openapi-en.yaml","api-reference/gpt-image-2-all-chat-openapi.yaml","api-reference/gpt-image-2-all-chat-openapi-en.yaml","api-reference/gpt-image-2-vip-generate-openapi.yaml","api-reference/gpt-image-2-vip-edit-openapi.yaml","api-reference/gpt-image-2-vip-chat-openapi.yaml","api-reference/gpt-image-2-vip-generate-openapi-en.yaml","api-reference/gpt-image-2-vip-edit-openapi-en.yaml","api-reference/gpt-image-2-vip-chat-openapi-en.yaml"],"playground":{"display":"interactive","proxy":true},"examples":{"defaults":"required"}},"navbar":{"links":[{"href":"https://api.apiyi.com","label":"首页"},{"href":"https://imagen.apiyi.com","label":"AI出图"},{"href":"https://icover.ai","label":"AI视频"}],"primary":{"type":"button","label":"控制台","href":"https://api.apiyi.com/account/profile"}},"footer":{"socials":{"website":"https://api.apiyi.com"},"links":[{"header":"AI 集成","items":[{"label":"skill.md","href":"https://docs.apiyi.com/skill.md"},{"label":"llms.txt","href":"https://docs.apiyi.com/llms.txt"},{"label":"llms-full.txt","href":"https://docs.apiyi.com/llms-full.txt"},{"label":"model-registry.json","href":"https://docs.apiyi.com/model-registry.json"},{"label":"AI 开发者套件(中文)","href":"/developer-kit"},{"label":"AI Developer Kit (EN)","href":"/en/developer-kit"}]},{"header":"用户口碑 / Wall of Love","items":[{"label":"用户口碑(中文)","href":"/wall-of-love"},{"label":"Wall of Love (EN)","href":"/en/wall-of-love"}]}]},"seo":{"indexing":"all"},"icons":{"library":"lucide"},"banner":{"content":"🚀 **GPT Image 2.6 Sunburst 和 Flare 均已上线,支持 GIF 输出,低至 83 折(17% off) | Now Live**:[详情 Details](https://docs.apiyi.com/api-capabilities/gpt-image-2/gpt-image-2-6)","dismissible":true},"contextual":{"options":["copy","view","chatgpt","claude","perplexity","aistudio"],"display":"header"},"metadata":{"timestamp":false},"styling":{"latex":true},"navigation":{"global":{"anchors":[]},"languages":[{"language":"zh","href":""},{"language":"en","navbar":{"links":[{"href":"https://api.apiyi.com","label":"Home"},{"href":"https://imagen.apiyi.com","label":"AI Image"},{"href":"https://icover.ai","label":"AI Video"}],"primary":{"type":"button","label":"Console","href":"https://api.apiyi.com/account/profile"}},"href":"en"},{"language":"zh-Hant","banner":{"content":"本頁由程式自動轉換為繁體中文,用詞以台灣正體為準;如有歧義請以[簡體中文版](/)為準。","dismissible":true},"footer":{"socials":{"website":"https://api.apiyi.com"},"links":[{"header":"AI 整合","items":[{"label":"skill.md","href":"https://docs.apiyi.com/skill.md"},{"label":"llms.txt","href":"https://docs.apiyi.com/llms.txt"},{"label":"llms-full.txt","href":"https://docs.apiyi.com/llms-full.txt"},{"label":"model-registry.json","href":"https://docs.apiyi.com/model-registry.json"},{"label":"AI 開發者套件(中文)","href":"/developer-kit"},{"label":"AI Developer Kit (EN)","href":"/en/developer-kit"}]},{"header":"使用者口碑 / Wall of Love","items":[{"label":"使用者口碑(中文)","href":"/wall-of-love"},{"label":"Wall of Love (EN)","href":"/en/wall-of-love"}]}]},"navbar":{"links":[{"href":"https://api.apiyi.com","label":"首頁"},{"href":"https://imagen.apiyi.com","label":"AI出圖"},{"href":"https://icover.ai","label":"AI影片"}],"primary":{"type":"button","label":"控制台","href":"https://api.apiyi.com/account/profile"}},"href":"zh-Hant"},{"language":"ja","banner":{"content":"このページは AI により翻訳されています。内容に相違がある場合は[English 版](/en)を正としてください。","dismissible":true},"footer":{"socials":{"website":"https://api.apiyi.com"},"links":[{"header":"AI統合","items":[{"label":"skill.md","href":"https://docs.apiyi.com/skill.md"},{"label":"llms.txt","href":"https://docs.apiyi.com/llms.txt"},{"label":"llms-full.txt","href":"https://docs.apiyi.com/llms-full.txt"},{"label":"model-registry.json","href":"https://docs.apiyi.com/model-registry.json"},{"label":"AI開発者キット(中国語)","href":"/developer-kit"},{"label":"AI Developer Kit (EN)","href":"/en/developer-kit"}]},{"header":"ユーザーの声 / Wall of Love","items":[{"label":"ユーザーの声(中国語)","href":"/wall-of-love"},{"label":"Wall of Love(英語)","href":"/en/wall-of-love"}]}]},"navbar":{"links":[{"href":"https://api.apiyi.com","label":"ホーム"},{"href":"https://imagen.apiyi.com","label":"AI画像生成"},{"href":"https://icover.ai","label":"AI動画生成"}],"primary":{"type":"button","label":"コンソール","href":"https://api.apiyi.com/account/profile"}},"href":"ja"},{"language":"ko","banner":{"content":"이 페이지는 AI로 번역되었습니다. 내용이 다를 경우 [English 버전](/en)을 기준으로 하십시오.","dismissible":true},"footer":{"socials":{"website":"https://api.apiyi.com"},"links":[{"header":"AI 통합","items":[{"label":"skill.md","href":"https://docs.apiyi.com/skill.md"},{"label":"llms.txt","href":"https://docs.apiyi.com/llms.txt"},{"label":"llms-full.txt","href":"https://docs.apiyi.com/llms-full.txt"},{"label":"model-registry.json","href":"https://docs.apiyi.com/model-registry.json"},{"label":"AI 개발자 키트(중국어)","href":"/developer-kit"},{"label":"AI Developer Kit (EN)","href":"/en/developer-kit"}]},{"header":"사용자 후기 / Wall of Love","items":[{"label":"사용자 후기(중국어)","href":"/wall-of-love"},{"label":"Wall of Love (영문)","href":"/en/wall-of-love"}]}]},"navbar":{"links":[{"href":"https://api.apiyi.com","label":"홈"},{"href":"https://imagen.apiyi.com","label":"AI 이미지 생성"},{"href":"https://icover.ai","label":"AI 동영상 생성"}],"primary":{"type":"button","label":"콘솔","href":"https://api.apiyi.com/account/profile"}},"href":"ko"},{"language":"ru","banner":{"content":"Эта страница переведена с помощью ИИ. При расхождениях ориентируйтесь на [английскую версию](/en).","dismissible":true},"footer":{"socials":{"website":"https://api.apiyi.com"},"links":[{"header":"AI-интеграция","items":[{"label":"skill.md","href":"https://docs.apiyi.com/skill.md"},{"label":"llms.txt","href":"https://docs.apiyi.com/llms.txt"},{"label":"llms-full.txt","href":"https://docs.apiyi.com/llms-full.txt"},{"label":"model-registry.json","href":"https://docs.apiyi.com/model-registry.json"},{"label":"Набор AI-разработчика (кит.)","href":"/developer-kit"},{"label":"AI Developer Kit (EN)","href":"/en/developer-kit"}]},{"header":"Отзывы пользователей / Wall of Love","items":[{"label":"Отзывы пользователей (на китайском)","href":"/wall-of-love"},{"label":"Wall of Love (EN)","href":"/en/wall-of-love"}]}]},"navbar":{"links":[{"href":"https://api.apiyi.com","label":"Главная"},{"href":"https://imagen.apiyi.com","label":"Генерация изображений"},{"href":"https://icover.ai","label":"Генерация видео"}],"primary":{"type":"button","label":"Консоль","href":"https://api.apiyi.com/account/profile"}},"href":"ru"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"apiyillc","hasAudioNarration":false,"actualSubdomain":"apiyillc","customDomains":["docs.apiyi.com"],"gitSource":{"type":"github","owner":"pdmaker","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":true,"agentFeedback":true},"entitlements":{},"buildId":"6af5cad1043c55511fa6440d","clientVersion":"0.0.4111","searchFilterCounts":[{"language":"zh","tag":"首页","count":216},{"language":"en","tag":"Home","count":216},{"language":"ja","tag":"ホーム","count":216},{"language":"ko","tag":"홈","count":216},{"language":"ru","tag":"Главная","count":216},{"language":"zh-Hant","tag":"首頁","count":216},{"language":"zh","tag":"图片 API(官转)","count":86},{"language":"en","tag":"Image API (Official)","count":86},{"language":"ja","tag":"画像API(公式)","count":86},{"language":"ko","tag":"이미지 API (공식)","count":86},{"language":"ru","tag":"Image API (официальный)","count":86},{"language":"zh-Hant","tag":"圖片 API(官轉)","count":86},{"language":"zh","tag":"公告","count":81},{"language":"en","tag":"Announcements","count":81},{"language":"zh","tag":"AI风向标","count":78},{"language":"en","tag":"AI Radar","count":78},{"language":"zh","tag":"常见问题","count":63},{"language":"en","tag":"FAQ","count":63},{"language":"ja","tag":"FAQ","count":63},{"language":"ko","tag":"FAQ","count":63},{"language":"ru","tag":"FAQ","count":63},{"language":"zh-Hant","tag":"常見問題","count":63},{"language":"zh","tag":"使用场景","count":50},{"language":"en","tag":"Use Cases","count":50},{"language":"ja","tag":"活用例","count":50},{"language":"ko","tag":"활용 사례","count":50},{"language":"ru","tag":"Сценарии использования","count":50},{"language":"zh-Hant","tag":"使用場景","count":50},{"language":"zh","tag":"基础 API","count":47},{"language":"en","tag":"Basic API","count":47},{"language":"ja","tag":"基本API","count":47},{"language":"ko","tag":"기본 API","count":47},{"language":"ru","tag":"Базовый API","count":47},{"language":"zh-Hant","tag":"基礎 API","count":47},{"language":"zh","tag":"模型价格","count":36},{"language":"en","tag":"Model Pricing","count":36},{"language":"ja","tag":"モデル料金","count":36},{"language":"ko","tag":"모델 요금","count":36},{"language":"ru","tag":"Цены на модели","count":36},{"language":"zh-Hant","tag":"模型價格","count":36},{"language":"zh","tag":"视频 API(官转)","count":35},{"language":"en","tag":"Video API (Official)","count":35},{"language":"ja","tag":"動画API(公式)","count":35},{"language":"ko","tag":"동영상 API (공식)","count":35},{"language":"ru","tag":"Video API (официальный)","count":35},{"language":"zh-Hant","tag":"影片 API(官轉)","count":35},{"language":"zh","tag":"文本生成","count":28},{"language":"en","tag":"Text Generation","count":28},{"language":"ja","tag":"テキスト生成","count":28},{"language":"ko","tag":"텍스트 생성","count":28},{"language":"ru","tag":"Генерация текста","count":28},{"language":"zh-Hant","tag":"文本生成","count":28},{"language":"ja","tag":"課金とセキュリティ","count":17},{"language":"ko","tag":"결제 및 보안","count":17},{"language":"ru","tag":"Оплата и безопасность","count":17},{"language":"zh-Hant","tag":"充值與安全","count":17},{"language":"ja","tag":"NanoBananaベストプラクティス","count":15},{"language":"ko","tag":"NanoBanana 모범 사례","count":15},{"language":"ru","tag":"Лучшие практики NanoBanana","count":15},{"language":"zh-Hant","tag":"NanoBanana最佳實踐","count":15}]},"assistantConfig":{},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"models/models.css","content":".mp-layout{display:flex;gap:2.5rem;max-width:1400px;margin:0 auto;padding:2.5rem 1.5rem 4rem;font-size:15px;line-height:1.7;color:rgb(var(--gray-500, 113 115 119))}html.dark .mp-layout{color:rgb(var(--gray-400, 159 161 165))}.mp-rail{display:none}@media (min-width: 1024px){.mp-rail{display:block;width:13rem;flex-shrink:0}}.mp-rail-nav{position:sticky;top:9.25rem;font-size:0.875rem}.mp-rail-head{font-weight:600;margin:0 0 0.375rem;color:rgb(var(--gray-900, 23 25 29))}html.dark .mp-rail-head{color:rgb(var(--gray-200, 223 225 229))}.mp-rail-link{display:block;padding:0.22rem 0;color:rgb(var(--gray-500, 113 115 119));text-decoration:none;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mp-rail-link:hover{color:rgb(var(--primary, 37 99 235))}html.dark .mp-rail-link{color:rgb(var(--gray-400, 159 161 165))}html.dark .mp-rail-link:hover{color:rgb(var(--primary-light, 59 130 246))}.mp-rail-vendors{max-height:45vh;overflow-y:auto}.mp-mt{margin-top:1rem}.mp-content{min-width:0;flex:1}.mp-title{font-size:2rem;font-weight:700;letter-spacing:-0.02em;margin:0 0 0.5rem;color:rgb(var(--gray-900, 23 25 29))}html.dark .mp-title{color:#fff}.mp-desc{color:rgb(var(--gray-500, 113 115 119));margin:0 0 1.5rem}html.dark .mp-desc{color:rgb(var(--gray-400, 159 161 165))}.mp-content h2{font-size:1.375rem;font-weight:600;margin:2.75rem 0 1rem;padding-bottom:0.45rem;border-bottom:1px solid rgb(var(--gray-200, 223 225 229) / 0.7);color:rgb(var(--gray-900, 23 25 29));scroll-margin-top:12rem}@media (min-width: 1024px){.mp-content h2{scroll-margin-top:16.5rem}}html.dark .mp-content h2{border-color:rgb(255 255 255 / 0.1);color:#fff}.mp-content p{margin:0.75rem 0}.mp-content ul{margin:0.75rem 0;padding-left:1.4rem}.mp-content li{margin:0.4rem 0}.mp-content strong{color:rgb(var(--gray-900, 23 25 29))}html.dark .mp-content strong{color:#fff}.mp-content a{color:rgb(var(--primary, 37 99 235));text-decoration:none}.mp-content a:hover{text-decoration:underline}html.dark .mp-content a{color:rgb(var(--primary-light, 59 130 246))}.mp-content code{font-size:0.85em;background:rgb(var(--gray-100, 239 241 245) / 0.8);border:1px solid rgb(var(--gray-200, 223 225 229) / 0.7);padding:0.1em 0.35em;border-radius:0.375rem}html.dark .mp-content code{background:rgb(255 255 255 / 0.06);border-color:rgb(255 255 255 / 0.1)}.mp-content code.mp-ep-rec{color:rgb(var(--primary, 37 99 235));background:rgb(var(--primary, 37 99 235) / 0.08);border-color:rgb(var(--primary, 37 99 235) / 0.45);font-weight:600}html.dark .mp-content code.mp-ep-rec{color:rgb(var(--primary-light, 59 130 246));background:rgb(var(--primary-light, 59 130 246) / 0.14);border-color:rgb(var(--primary-light, 59 130 246) / 0.5)}.mp-content table{display:block;max-width:100%;overflow-x:auto;border-collapse:collapse;font-size:0.875rem;margin:1rem 0 1.5rem}.mp-content th{text-align:left;font-weight:500;color:rgb(var(--gray-500, 113 115 119));padding:0.55rem 1.25rem 0.55rem 0;border-bottom:1px solid rgb(var(--gray-200, 223 225 229) / 0.7);white-space:nowrap}.mp-content td{padding:0.55rem 1.25rem 0.55rem 0;border-bottom:1px solid rgb(var(--gray-200, 223 225 229) / 0.45);white-space:nowrap}html.dark .mp-content th{border-color:rgb(255 255 255 / 0.1);color:rgb(var(--gray-400, 159 161 165))}html.dark .mp-content td{border-color:rgb(255 255 255 / 0.07)}.mp-search{display:contents}.mp-search-bar{position:sticky;top:5rem;z-index:20;margin:0 0 1.75rem;background:rgb(var(--background-light, 255 255 255));padding:0.75rem 0 0.85rem;box-shadow:0 10px 14px -10px rgb(var(--gray-950, 11 13 17) / 0.28)}@media (min-width: 1024px){.mp-search-bar{top:9.25rem}}html.dark .mp-search-bar{background:rgb(var(--background-dark, 10 11 16));box-shadow:0 8px 12px -10px rgb(0 0 0 / 0.7)}.mp-search-label{margin:0 0 0.5rem;padding-left:0.6rem;border-left:3px solid rgb(var(--primary, 37 99 235));font-size:0.9rem;font-weight:600;line-height:1.4;color:rgb(var(--primary, 37 99 235))}html.dark .mp-search-label{border-left-color:rgb(var(--primary-light, 59 130 246));color:rgb(var(--primary-light, 59 130 246))}.mp-search-input{width:100%;box-sizing:border-box;border:1px solid rgb(var(--gray-400, 159 161 165) / 0.3);border-radius:0.75rem;padding:0.7rem 1rem 0.7rem 2.65rem;font-size:0.9rem;background-color:rgb(var(--background-light, 255 255 255));background-image:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23717377' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='m21 21-4.3-4.3'/%3E%3C/svg%3E\");background-repeat:no-repeat;background-position:0.9rem center;color:rgb(var(--gray-900, 23 25 29));outline:none;transition:border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease}.mp-search-input::placeholder{color:rgb(var(--gray-500, 113 115 119))}.mp-search-input:hover{border-color:rgb(var(--gray-600, 81 83 87) / 0.3)}.mp-search-input:focus{border-color:rgb(var(--primary, 37 99 235));box-shadow:0 0 0 3px rgb(var(--primary, 37 99 235) / 0.16)}html.dark .mp-search-input{background-color:rgb(var(--background-dark, 10 11 16));background-image:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%239fa1a5' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='m21 21-4.3-4.3'/%3E%3C/svg%3E\");border-color:rgb(var(--gray-600, 81 83 87) / 0.3);color:rgb(var(--gray-100, 239 241 245))}html.dark .mp-search-input::placeholder{color:rgb(255 255 255 / 0.5)}html.dark .mp-search-input:hover{border-color:rgb(var(--gray-500, 113 115 119) / 0.35)}html.dark .mp-search-input:focus{border-color:rgb(var(--primary-light, 59 130 246));box-shadow:0 0 0 3px rgb(var(--primary-light, 59 130 246) / 0.22)}.mp-search-meta{font-size:0.75rem;color:rgb(var(--gray-500, 113 115 119));margin:0.75rem 0 0.25rem}.mp-search-empty{font-size:0.875rem;color:rgb(var(--gray-500, 113 115 119));margin-top:0.75rem}html.dark .mp-search-meta,html.dark .mp-search-empty{color:rgb(var(--gray-400, 159 161 165))}.mp-mono{font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;font-size:0.8125rem}@media (min-width: 1024px){.mp-jump{display:none}}"},{"filePath":"styles/agent-prompt.css","content":"div.prompt{border:1.5px solid rgb(var(--primary, 37 99 235) / 0.35);background:rgb(var(--primary, 37 99 235) / 0.035);padding:1.25rem 1.25rem 1rem;row-gap:0.75rem}html.dark div.prompt{border-color:rgb(var(--primary-light, 59 130 246) / 0.4);background:rgb(var(--primary-light, 59 130 246) / 0.06)}div.prompt [data-component-part=\"prompt-content-wrapper\"]{width:100%}div.prompt [data-component-part=\"prompt-actions-wrapper\"]{width:100%;justify-content:flex-end}div.prompt [data-component-part=\"prompt-description\"]{flex:1;font-size:14px;line-height:1.65}div.prompt [data-component-part=\"prompt-description\"]>div>*{margin:0}div.prompt [data-component-part=\"prompt-description\"]>div>*+*{margin-top:0.6rem}div.prompt [data-component-part=\"prompt-description\"] strong{font-size:15px;font-weight:650;color:rgb(var(--gray-900, 23 25 29))}html.dark div.prompt [data-component-part=\"prompt-description\"] strong{color:#fff}div.prompt [data-component-part=\"prompt-description\"]>div>*+p{color:rgb(var(--gray-600, 80 82 86))}html.dark div.prompt [data-component-part=\"prompt-description\"]>div>*+p{color:rgb(var(--gray-400, 159 161 165))}div.prompt [data-component-part=\"prompt-description\"] code{font-size:0.85em;background:rgb(var(--gray-100, 239 241 245) / 0.9);border:1px solid rgb(var(--gray-200, 223 225 229) / 0.7);padding:0.05em 0.35em;border-radius:0.375rem}html.dark div.prompt [data-component-part=\"prompt-description\"] code{background:rgb(255 255 255 / 0.06);border-color:rgb(255 255 255 / 0.1)}div.prompt [data-component-part=\"prompt-description\"] blockquote{margin:0;padding:0.75rem 0.9rem;font-style:normal;border:1px dashed rgb(var(--gray-300, 191 193 197));border-radius:0.6rem;background:rgb(var(--background-light, 255 255 255));font-family:ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;font-size:12.5px;line-height:1.6;color:rgb(var(--gray-600, 80 82 86));overflow-wrap:anywhere;-webkit-mask-image:linear-gradient(to bottom, #000 70%, transparent 100%);mask-image:linear-gradient(to bottom, #000 70%, transparent 100%)}div.prompt [data-component-part=\"prompt-description\"] blockquote p,div.prompt [data-component-part=\"prompt-description\"] blockquote ol{margin:0}div.prompt [data-component-part=\"prompt-description\"] blockquote li{padding:0}div.prompt [data-component-part=\"prompt-description\"] blockquote>*+*{margin-top:0.5rem}div.prompt [data-component-part=\"prompt-description\"] blockquote code{background:none;border:0;padding:0;font-size:1em}div.prompt [data-component-part=\"prompt-description\"] blockquote a{color:inherit;text-decoration:none;pointer-events:none}html.dark div.prompt [data-component-part=\"prompt-description\"] blockquote{border-color:rgb(255 255 255 / 0.15);background:rgb(var(--background-dark, 13 13 13));color:rgb(var(--gray-400, 159 161 165))}div.prompt [data-component-part=\"prompt-action-copy-button\"]{padding:0.6rem 1.25rem;font-size:14px;line-height:20px;font-weight:600;border-radius:0.65rem;gap:0.45rem;box-shadow:0 1px 2px rgb(0 0 0 / 0.08), 0 4px 12px rgb(var(--primary, 37 99 235) / 0.25)}div.prompt [data-component-part=\"prompt-action-copy-button\"]::before{content:\"\";width:16px;height:16px;flex-shrink:0;background:currentColor;-webkit-mask:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect width='14' height='14' x='8' y='8' rx='2' ry='2'/%3E%3Cpath d='M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2'/%3E%3C/svg%3E\") center / contain no-repeat;mask:url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect width='14' height='14' x='8' y='8' rx='2' ry='2'/%3E%3Cpath d='M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2'/%3E%3C/svg%3E\") center / contain no-repeat}div.prompt [data-component-part=\"prompt-action-copy-button\"] svg{width:12px;height:12px}@media (max-width: 640px){div.prompt [data-component-part=\"prompt-actions-wrapper\"]>*{flex:1}}"}],"page":{"pagePath":"ru/faq/http-vs-http11","slug":"/ru/faq/http-vs-http11","pageMetadata":{"title":"Является ли http тем же самым, что и HTTP/1.1?","description":"http/https отвечает за шифрование; HTTP/1.1 и HTTP/2 определяют, как в соединении передаются запросы. Это разные вещи. Большинству пользователей следует просто использовать https://api.apiyi.com.","icon":"network","href":"/ru/faq/http-vs-http11"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n a: \"a\",\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_components.p, {\n children: [\"http/https отвечает за шифрование; HTTP/1.1 и HTTP/2 определяют, как в соединении передаются запросы. Это разные вещи. Большинству пользователей следует просто использовать \", _jsx(_components.a, {\n href: \"https://api.apiyi.com\",\n children: \"https://api.apiyi.com\"\n }), \".\"]\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{Accordion,AccordionGroup,CodeBlock,Heading,Step,Steps,Table,Warning}=_components;if(!Accordion)_missingMdxReference(`Accordion`,true);if(!AccordionGroup)_missingMdxReference(`AccordionGroup`,true);if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Step)_missingMdxReference(`Step`,true);if(!Steps)_missingMdxReference(`Steps`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(Heading,{level:`2`,id:`краткий-ответ`,children:`Краткий ответ`}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Нет.`}),` `,_jsx(_components.code,{children:`http://`}),` или `,_jsx(_components.code,{children:`https://`}),` определяет, `,_jsx(_components.strong,{children:`зашифрован ли трафик`}),`. HTTP/1.1 или HTTP/2 — это `,_jsx(_components.strong,{children:`версия протокола`}),`, которая определяет, как запросы передаются по соединению. Возможна любая их комбинация.`]}),`\n`,_jsx(_components.p,{children:`Почти всем пользователям следует просто использовать этот адрес и ничего не менять:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`https://api.apiyi.com`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(Heading,{level:`2`,id:`два-отдельных-измерения`,children:`Два отдельных измерения`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Измерение`}),_jsx(_components.th,{children:`Что определяет`}),_jsx(_components.th,{children:`Значения`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[_jsx(_components.code,{children:`http://`}),` или `,_jsx(_components.code,{children:`https://`})]}),_jsx(_components.td,{children:`Шифруется ли трафик (с TLS или без)`}),_jsx(_components.td,{children:`Открытый текст / зашифрованный`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`HTTP/1.1 или HTTP/2`}),_jsx(_components.td,{children:`Как запросы передаются по одному соединению`}),_jsxs(_components.td,{children:[`HTTP/1.1: один запрос за раз на соединение, поэтому параллельные запросы означают больше соединений`,_jsx(`br`,{}),`HTTP/2: множество запросов используют одно соединение (мультиплексирование)`]})]})]})]}),`\n`,_jsxs(_components.p,{children:[`Версия протокола `,_jsx(_components.strong,{children:`согласовывается между клиентом и сервером при установке соединения`}),`. Она не определяется тем, как записан URL. Эндпоинт `,_jsx(_components.code,{children:`https://`}),` APIYI поддерживает как HTTP/1.1, так и HTTP/2 и использует тот протокол, который поддерживает ваш клиент.`]}),`\n`,_jsx(_components.p,{children:`Поэтому распространенное мнение о том, что «http означает HTTP/1.1, а https означает HTTP/2», является заблуждением:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`Для адресов `,_jsx(_components.code,{children:`http://`}),` популярные клиенты практически всегда используют HTTP/1.1, но это лишь совпадение результата`]}),`\n`,_jsxs(_components.li,{children:[`Для адресов `,_jsx(_components.code,{children:`https://`}),` некоторые клиенты используют HTTP/1.1, а другие — HTTP/2, в зависимости от самого клиента`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`версия-по-умолчанию-для-распространенных-клиентов-по-https`,children:`Версия по умолчанию для распространенных клиентов (по https)`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Клиент`}),_jsx(_components.th,{children:`Версия по умолчанию`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Python `,_jsx(_components.code,{children:`requests`}),`, `,_jsx(_components.code,{children:`httpx`}),`, OpenAI Python SDK`]}),_jsx(_components.td,{children:`HTTP/1.1`})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Node.js `,_jsx(_components.code,{children:`axios`})]}),_jsx(_components.td,{children:`HTTP/1.1`})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Встроенный в Node.js `,_jsx(_components.code,{children:`fetch`}),`, OpenAI Node SDK`]}),_jsxs(_components.td,{children:[`Node 25 и ранее: HTTP/1.1; `,_jsx(_components.strong,{children:`Node 26 и новее по умолчанию согласовывают HTTP/2`})]})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Стандартная библиотека Go `,_jsx(_components.code,{children:`net/http`}),` (используется такими шлюзами, как new-api и one-api)`]}),_jsx(_components.td,{children:`HTTP/2`})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[`Java `,_jsx(_components.code,{children:`HttpClient`}),`, OkHttp`]}),_jsx(_components.td,{children:`HTTP/2`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:`curl, браузеры`}),_jsx(_components.td,{children:`HTTP/2`})]})]})]}),`\n`,_jsx(_components.p,{children:`Чтобы проверить, какую версию вы действительно используете, выполните curl:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`3`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`3`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -s`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -o`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` /dev/null`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -w`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"%{http_version}\\\\n\"`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.apiyi.com/v1/models`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer YOUR_API_KEY\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`# 2 means HTTP/2, 1.1 means HTTP/1.1`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`какой-адрес-использовать`,children:`Какой адрес использовать?`}),`\n`,_jsxs(Steps,{children:[_jsx(Step,{title:`Конечные пользователи: используйте https и ничего не меняйте`,children:_jsxs(_components.p,{children:[`Физические лица и компании, вызывающие API напрямую, должны использовать `,_jsx(_components.code,{children:`https://api.apiyi.com`}),`. Стандартные SDK для Python, Node и других языков отлично работают по умолчанию, без необходимости настройки протокола.`]})}),_jsx(Step,{title:`Клиенты на Go / Java с большим количеством параллельных запросов на загрузку изображений: оставьте https, отключите HTTP/2 в клиенте`,children:_jsxs(_components.p,{children:[`HTTP/2 объединяет множество параллельных запросов в одном соединении. При загрузке изображений размером в несколько МБ любая заминка в этом соединении замедляет каждый проходящий по нему запрос. Если ваш клиент по умолчанию использует HTTP/2 и вы выполняете генерацию или редактирование изображений с большим количеством параллельных запросов, переключите клиент на HTTP/1.1. `,_jsx(_components.strong,{children:`Сохраняйте адрес https; переходить на http не требуется.`})]})}),_jsx(Step,{title:`http://api.apiyi.com:16888: только как резервный вариант`,children:_jsxs(_components.p,{children:[`Это официально предоставляемый незашифрованный эндпоинт. Используйте его только в качестве временного решения, когда само рукопожатие HTTPS завершается ошибкой (например, `,_jsx(_components.a,{href:`/ru/faq/openssl-pq-handshake-eof`,children:`Python выдаёт SSLEOFError, но curl работает?`}),`), либо внутри доверенной внутренней сети или выделенной линии связи.`]})})]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.code,{children:`http://`}),` не зашифрован. Ваш ключ API, prompts и изображения передаются по публичной сети в виде открытого текста и видны любому сетевому устройству на пути следования. Не полагайтесь на незашифрованный эндпоинт как на долгосрочное решение для продакшена.`]})}),`\n`,_jsx(Heading,{level:`3`,id:`как-переключить-клиент-go-на-http/1-1`,children:`Как переключить клиент Go на HTTP/1.1`}),`\n`,_jsx(_components.p,{children:`Вариант без изменения кода — установить переменную окружения для процесса. Это подходит для готовых программ-шлюзов, таких как new-api и one-api:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`GODEBUG`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`http2client`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`0`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`В собственном коде задайте для `,_jsx(_components.code,{children:`Transport.TLSNextProto`}),` не равную nil пустую map:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`11`,language:`go`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`go`,children:_jsxs(_components.code,{language:`go`,numberOfLines:`11`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#CE9178`},children:`crypto/tls`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#CE9178`},children:`net/http`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`tr`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u0026`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`http`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`Transport`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:` // A non-nil empty map disables HTTP/2, so https requests use HTTP/1.1`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` TLSNextProto`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`map`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`[`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#4EC9B0`},children:`string`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`func`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#4EC9B0`},children:`string`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`*`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`tls`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`Conn`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`http`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`RoundTripper`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{},`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` MaxIdleConnsPerHost`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`100`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`client`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` :=`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u0026`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`http`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#4EC9B0`},children:`Client`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`Transport`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`tr`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`распространенные-заблуждения`,children:`Распространенные заблуждения`}),`\n`,_jsxs(AccordionGroup,{children:[_jsx(Accordion,{title:`Быстрее ли http://?`,id:`bystree-li-http`,children:_jsx(_components.p,{children:`Для клиентов, которые уже используют HTTP/1.1, таких как Python и Node, переход на http экономит всего одно рукопожатие TLS (долю секунды). Это ничтожно мало по сравнению со временем генерации изображений в десятки секунд, и при этом вы теряете шифрование.`})}),_jsx(Accordion,{title:`Нужно ли переходить на http://, чтобы отключить HTTP/2?`,id:`nuzhno-li-perekhodit-na-http-chtoby-otklyuchit-http-2`,children:_jsxs(_components.p,{children:[`Нет. HTTP/2 отключается на стороне клиента; см. пример для Go выше. В других языках есть аналогичные параметры. После этого продолжайте использовать `,_jsx(_components.code,{children:`https://api.apiyi.com`}),`, и вы получите HTTP/1.1 с шифрованием.`]})}),_jsx(Accordion,{title:`HTTP/2 — это плохо?`,id:`http-2-eto-plokho`,children:_jsx(_components.p,{children:`Нет. Для браузеров и обычных текстовых чатов, где запросы небольшие и многочисленные, повторное использование соединений в HTTP/2 экономит ресурсы. Единое мультиплексированное соединение становится узким местом только тогда, когда большое количество параллельных запросов сочетается с большими телами запросов или ответов.`})})]}),`\n`,_jsx(Heading,{level:`2`,id:`связанная-документация`,children:`Связанная документация`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`/ru/faq/base-url-config`,children:`Как настроить базовый URL?`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`/ru/faq/image-api-network-latency-optimization`,children:`Как снизить задержку API изображений?`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`/ru/faq/openssl-pq-handshake-eof`,children:`Python выдает SSLEOFError, но curl работает?`})}),`\n`,_jsx(_components.li,{children:_jsx(_components.a,{href:`/ru/faq/proxy-empty-502`,children:`Скрипт получает 502, но в логах вызовов ничего нет?`})}),`\n`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Является ли http тем же самым, что и HTTP/1.1?","description":"http/https отвечает за шифрование; HTTP/1.1 и HTTP/2 определяют, как в соединении передаются запросы. Это разные вещи. Большинству пользователей следует просто использовать https://api.apiyi.com.","icon":"network","href":"/ru/faq/http-vs-http11"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Краткий ответ","slug":"краткий-ответ","depth":2,"children":[]},{"title":"Два отдельных измерения","slug":"два-отдельных-измерения","depth":2,"children":[]},{"title":"Версия по умолчанию для распространенных клиентов (по https)","slug":"версия-по-умолчанию-для-распространенных-клиентов-по-https","depth":2,"children":[]},{"title":"Какой адрес использовать?","slug":"какой-адрес-использовать","depth":2,"children":[{"title":"Как переключить клиент Go на HTTP/1.1","slug":"как-переключить-клиент-go-на-http/1-1","depth":3,"children":[]}]},{"title":"Распространенные заблуждения","slug":"распространенные-заблуждения","depth":2,"children":[]},{"title":"Связанная документация","slug":"связанная-документация","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"subdomain":"apiyillc","siteName":"API易文档中心","title":"Является ли http тем же самым, что и HTTP/1.1? - API易文档中心","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"zh":{"href":"/faq/http-vs-http11","matchLevel":1},"en":{"href":"/en/faq/http-vs-http11","matchLevel":1},"zh-Hant":{"href":"/zh-Hant/faq/http-vs-http11","matchLevel":1},"ja":{"href":"/ja/faq/http-vs-http11","matchLevel":1},"ko":{"href":"/ko/faq/http-vs-http11","matchLevel":1},"ru":{"href":"/ru/faq/http-vs-http11","matchLevel":0}}},"lastModified":"2026-09-28T05:32:56.924Z","originalFileLocation":"ru/faq/http-vs-http11.mdx","locale":"ru"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"http/https отвечает за шифрование; HTTP/1.1 и HTTP/2 определяют, как в соединении передаются запросы. Это разные вещи. Большинству пользователей следует просто использовать https://api.apiyi.com.\">\u003cmeta data-mint-head name=\"application-name\" content=\"API易文档中心\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/apiyillc/sQlsuRwD6o27XLvg/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/apiyillc/sQlsuRwD6o27XLvg/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/apiyillc/sQlsuRwD6o27XLvg/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/apiyillc/sQlsuRwD6o27XLvg/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/apiyillc/sQlsuRwD6o27XLvg/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/apiyillc/sQlsuRwD6o27XLvg/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/apiyillc/sQlsuRwD6o27XLvg/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/apiyillc/sQlsuRwD6o27XLvg/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/apiyillc/sQlsuRwD6o27XLvg/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Является ли http тем же самым, что и HTTP/1.1? - API易文档中心\">\u003cmeta data-mint-head property=\"og:description\" content=\"http/https отвечает за шифрование; HTTP/1.1 и HTTP/2 определяют, как в соединении передаются запросы. Это разные вещи. Большинству пользователей следует просто использовать https://api.apiyi.com.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"API易文档中心\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.apiyi.com/ru/faq/http-vs-http11\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://apiyillc.mintlify.site/_mintlify/api/og/v2?division=%D0%A1%D0%B5%D1%82%D1%8C+%D0%B8+%D0%BF%D0%BE%D0%B4%D0%BA%D0%BB%D1%8E%D1%87%D0%B5%D0%BD%D0%B8%D0%B5\u0026amp;title=%D0%AF%D0%B2%D0%BB%D1%8F%D0%B5%D1%82%D1%81%D1%8F+%D0%BB%D0%B8+http+%D1%82%D0%B5%D0%BC+%D0%B6%D0%B5+%D1%81%D0%B0%D0%BC%D1%8B%D0%BC%2C+%D1%87%D1%82%D0%BE+%D0%B8+HTTP%2F1.1%3F\u0026amp;description=http%2Fhttps+%D0%BE%D1%82%D0%B2%D0%B5%D1%87%D0%B0%D0%B5%D1%82+%D0%B7%D0%B0+%D1%88%D0%B8%D1%84%D1%80%D0%BE%D0%B2%D0%B0%D0%BD%D0%B8%D0%B5%3B+HTTP%2F1.1+%D0%B8+HTTP%2F2+%D0%BE%D0%BF%D1%80%D0%B5%D0%B4%D0%B5%D0%BB%D1%8F%D1%8E%D1%82%2C+%D0%BA%D0%B0%D0%BA+%D0%B2+%D1%81%D0%BE%D0%B5%D0%B4%D0%B8%D0%BD%D0%B5%D0%BD%D0%B8%D0%B8+%D0%BF%D0%B5%D1%80%D0%B5%D0%B4%D0%B0%D1%8E%D1%82%D1%81%D1%8F+%D0%B7%D0%B0%D0%BF%D1%80%D0%BE%D1%81%D1%8B.+%D0%AD%D1%82%D0%BE+%D1%80%D0%B0%D0%B7%D0%BD%D1%8B%D0%B5+%D0%B2%D0%B5%D1%89%D0%B8.+%D0%91%D0%BE%D0%BB%D1%8C%D1%88%D0%B8%D0%BD%D1%81%D1%82%D0%B2%D1%83+%D0%BF%D0%BE%D0%BB%D1%8C%D0%B7%D0%BE%D0%B2%D0%B0%D1%82%D0%B5%D0%BB%D0%B5%D0%B9+%D1%81%D0%BB%D0%B5%D0%B4%D1%83%D0%B5%D1%82+%D0%BF%D1%80%D0%BE%D1%81%D1%82%D0%BE+\u0026amp;theme=84509e4a5d1cb12fd162de92\u0026amp;signature=9c355ac33cce82916af9839a119e59433e3fd86ec29563e805532cce20c56784\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Является ли http тем же самым, что и HTTP/1.1? - API易文档中心\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"http/https отвечает за шифрование; HTTP/1.1 и HTTP/2 определяют, как в соединении передаются запросы. Это разные вещи. Большинству пользователей следует просто использовать https://api.apiyi.com.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://apiyillc.mintlify.site/_mintlify/api/og/v2?division=%D0%A1%D0%B5%D1%82%D1%8C+%D0%B8+%D0%BF%D0%BE%D0%B4%D0%BA%D0%BB%D1%8E%D1%87%D0%B5%D0%BD%D0%B8%D0%B5\u0026amp;title=%D0%AF%D0%B2%D0%BB%D1%8F%D0%B5%D1%82%D1%81%D1%8F+%D0%BB%D0%B8+http+%D1%82%D0%B5%D0%BC+%D0%B6%D0%B5+%D1%81%D0%B0%D0%BC%D1%8B%D0%BC%2C+%D1%87%D1%82%D0%BE+%D0%B8+HTTP%2F1.1%3F\u0026amp;description=http%2Fhttps+%D0%BE%D1%82%D0%B2%D0%B5%D1%87%D0%B0%D0%B5%D1%82+%D0%B7%D0%B0+%D1%88%D0%B8%D1%84%D1%80%D0%BE%D0%B2%D0%B0%D0%BD%D0%B8%D0%B5%3B+HTTP%2F1.1+%D0%B8+HTTP%2F2+%D0%BE%D0%BF%D1%80%D0%B5%D0%B4%D0%B5%D0%BB%D1%8F%D1%8E%D1%82%2C+%D0%BA%D0%B0%D0%BA+%D0%B2+%D1%81%D0%BE%D0%B5%D0%B4%D0%B8%D0%BD%D0%B5%D0%BD%D0%B8%D0%B8+%D0%BF%D0%B5%D1%80%D0%B5%D0%B4%D0%B0%D1%8E%D1%82%D1%81%D1%8F+%D0%B7%D0%B0%D0%BF%D1%80%D0%BE%D1%81%D1%8B.+%D0%AD%D1%82%D0%BE+%D1%80%D0%B0%D0%B7%D0%BD%D1%8B%D0%B5+%D0%B2%D0%B5%D1%89%D0%B8.+%D0%91%D0%BE%D0%BB%D1%8C%D1%88%D0%B8%D0%BD%D1%81%D1%82%D0%B2%D1%83+%D0%BF%D0%BE%D0%BB%D1%8C%D0%B7%D0%BE%D0%B2%D0%B0%D1%82%D0%B5%D0%BB%D0%B5%D0%B9+%D1%81%D0%BB%D0%B5%D0%B4%D1%83%D0%B5%D1%82+%D0%BF%D1%80%D0%BE%D1%81%D1%82%D0%BE+\u0026amp;theme=84509e4a5d1cb12fd162de92\u0026amp;signature=9c355ac33cce82916af9839a119e59433e3fd86ec29563e805532cce20c56784\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/apiyillc/sQlsuRwD6o27XLvg/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"API易文档中心\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#2563eb\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.apiyi.com/ru/faq/http-vs-http11\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/ru/faq/http-vs-http11.md\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"ru\" href=\"https://docs.apiyi.com/ru/faq/http-vs-http11\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"zh\" href=\"https://docs.apiyi.com/faq/http-vs-http11\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"en\" href=\"https://docs.apiyi.com/en/faq/http-vs-http11\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"zh-Hant\" href=\"https://docs.apiyi.com/zh-Hant/faq/http-vs-http11\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"ja\" href=\"https://docs.apiyi.com/ja/faq/http-vs-http11\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"ko\" href=\"https://docs.apiyi.com/ko/faq/http-vs-http11\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"x-default\" href=\"https://docs.apiyi.com/faq/http-vs-http11\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.apiyi.com/#organization\",\"name\":\"API易文档中心\",\"url\":\"https://docs.apiyi.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/apiyillc/LjCT1O0GrSur6F2v/logo/light.svg?fit=max\u0026auto=format\u0026n=LjCT1O0GrSur6F2v\u0026q=85\u0026s=4119ef17a74cc54be127f34578d8b5fa\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.apiyi.com#website\",\"name\":\"API易文档中心\",\"url\":\"https://docs.apiyi.com\",\"publisher\":{\"@id\":\"https://docs.apiyi.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.apiyi.com/ru/faq/http-vs-http11#webpage\",\"url\":\"https://docs.apiyi.com/ru/faq/http-vs-http11\",\"name\":\"Является ли http тем же самым, что и HTTP/1.1?\",\"description\":\"http/https отвечает за шифрование; HTTP/1.1 и HTTP/2 определяют, как в соединении передаются запросы. Это разные вещи. Большинству пользователей следует просто использовать https://api.apiyi.com.\",\"dateModified\":\"2026-09-28T05:32:56.924Z\",\"isPartOf\":{\"@id\":\"https://docs.apiyi.com#website\"},\"breadcrumb\":{\"@id\":\"https://docs.apiyi.com/ru/faq/http-vs-http11#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.apiyi.com/ru/faq/http-vs-http11#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Сеть и подключение\",\"item\":\"https://docs.apiyi.com/ru/faq/timeout-configuration\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Является ли http тем же самым, что и HTTP/1.1?\",\"item\":\"https://docs.apiyi.com/ru/faq/http-vs-http11\"}]},{\"@type\":[\"Article\",\"TechArticle\"],\"@id\":\"https://docs.apiyi.com/ru/faq/http-vs-http11#article\",\"headline\":\"Является ли http тем же самым, что и HTTP/1.1?\",\"name\":\"Является ли http тем же самым, что и HTTP/1.1?\",\"description\":\"http/https отвечает за шифрование; HTTP/1.1 и HTTP/2 определяют, как в соединении передаются запросы. Это разные вещи. Большинству пользователей следует просто использовать https://api.apiyi.com.\",\"url\":\"https://docs.apiyi.com/ru/faq/http-vs-http11\",\"mainEntityOfPage\":{\"@id\":\"https://docs.apiyi.com/ru/faq/http-vs-http11#webpage\"},\"dateModified\":\"2026-09-28T05:32:56.924Z\",\"publisher\":{\"@id\":\"https://docs.apiyi.com/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.apiyi.com#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"API易文档中心\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"API易文档中心\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/ru/faq/http-vs-http11.md","siteName":"API易文档中心","nav":{"global":{"anchors":[]},"languages":[{"language":"zh","pages":[{"title":"zh","href":"/faq/http-vs-http11"}]},{"language":"en","navbar":{"links":[{"href":"https://api.apiyi.com","label":"Home"},{"href":"https://imagen.apiyi.com","label":"AI Image"},{"href":"https://icover.ai","label":"AI Video"}],"primary":{"type":"button","label":"Console","href":"https://api.apiyi.com/account/profile"}},"pages":[{"title":"en","href":"/en/faq/http-vs-http11"}]},{"language":"zh-Hant","banner":{"content":"本頁由程式自動轉換為繁體中文,用詞以台灣正體為準;如有歧義請以[簡體中文版](/)為準。","dismissible":true},"footer":{"socials":{"website":"https://api.apiyi.com"},"links":[{"header":"AI 整合","items":[{"label":"skill.md","href":"https://docs.apiyi.com/skill.md"},{"label":"llms.txt","href":"https://docs.apiyi.com/llms.txt"},{"label":"llms-full.txt","href":"https://docs.apiyi.com/llms-full.txt"},{"label":"model-registry.json","href":"https://docs.apiyi.com/model-registry.json"},{"label":"AI 開發者套件(中文)","href":"/developer-kit"},{"label":"AI Developer Kit (EN)","href":"/en/developer-kit"}]},{"header":"使用者口碑 / Wall of Love","items":[{"label":"使用者口碑(中文)","href":"/wall-of-love"},{"label":"Wall of Love (EN)","href":"/en/wall-of-love"}]}]},"navbar":{"links":[{"href":"https://api.apiyi.com","label":"首頁"},{"href":"https://imagen.apiyi.com","label":"AI出圖"},{"href":"https://icover.ai","label":"AI影片"}],"primary":{"type":"button","label":"控制台","href":"https://api.apiyi.com/account/profile"}},"pages":[{"title":"zh-Hant","href":"/zh-Hant/faq/http-vs-http11"}]},{"language":"ja","banner":{"content":"このページは AI により翻訳されています。内容に相違がある場合は[English 版](/en)を正としてください。","dismissible":true},"footer":{"socials":{"website":"https://api.apiyi.com"},"links":[{"header":"AI統合","items":[{"label":"skill.md","href":"https://docs.apiyi.com/skill.md"},{"label":"llms.txt","href":"https://docs.apiyi.com/llms.txt"},{"label":"llms-full.txt","href":"https://docs.apiyi.com/llms-full.txt"},{"label":"model-registry.json","href":"https://docs.apiyi.com/model-registry.json"},{"label":"AI開発者キット(中国語)","href":"/developer-kit"},{"label":"AI Developer Kit (EN)","href":"/en/developer-kit"}]},{"header":"ユーザーの声 / Wall of Love","items":[{"label":"ユーザーの声(中国語)","href":"/wall-of-love"},{"label":"Wall of Love(英語)","href":"/en/wall-of-love"}]}]},"navbar":{"links":[{"href":"https://api.apiyi.com","label":"ホーム"},{"href":"https://imagen.apiyi.com","label":"AI画像生成"},{"href":"https://icover.ai","label":"AI動画生成"}],"primary":{"type":"button","label":"コンソール","href":"https://api.apiyi.com/account/profile"}},"pages":[{"title":"ja","href":"/ja/faq/http-vs-http11"}]},{"language":"ko","banner":{"content":"이 페이지는 AI로 번역되었습니다. 내용이 다를 경우 [English 버전](/en)을 기준으로 하십시오.","dismissible":true},"footer":{"socials":{"website":"https://api.apiyi.com"},"links":[{"header":"AI 통합","items":[{"label":"skill.md","href":"https://docs.apiyi.com/skill.md"},{"label":"llms.txt","href":"https://docs.apiyi.com/llms.txt"},{"label":"llms-full.txt","href":"https://docs.apiyi.com/llms-full.txt"},{"label":"model-registry.json","href":"https://docs.apiyi.com/model-registry.json"},{"label":"AI 개발자 키트(중국어)","href":"/developer-kit"},{"label":"AI Developer Kit (EN)","href":"/en/developer-kit"}]},{"header":"사용자 후기 / Wall of Love","items":[{"label":"사용자 후기(중국어)","href":"/wall-of-love"},{"label":"Wall of Love (영문)","href":"/en/wall-of-love"}]}]},"navbar":{"links":[{"href":"https://api.apiyi.com","label":"홈"},{"href":"https://imagen.apiyi.com","label":"AI 이미지 생성"},{"href":"https://icover.ai","label":"AI 동영상 생성"}],"primary":{"type":"button","label":"콘솔","href":"https://api.apiyi.com/account/profile"}},"pages":[{"title":"ko","href":"/ko/faq/http-vs-http11"}]},{"language":"ru","banner":{"content":"Эта страница переведена с помощью ИИ. При расхождениях ориентируйтесь на [английскую версию](/en).","dismissible":true},"footer":{"socials":{"website":"https://api.apiyi.com"},"links":[{"header":"AI-интеграция","items":[{"label":"skill.md","href":"https://docs.apiyi.com/skill.md"},{"label":"llms.txt","href":"https://docs.apiyi.com/llms.txt"},{"label":"llms-full.txt","href":"https://docs.apiyi.com/llms-full.txt"},{"label":"model-registry.json","href":"https://docs.apiyi.com/model-registry.json"},{"label":"Набор AI-разработчика (кит.)","href":"/developer-kit"},{"label":"AI Developer Kit (EN)","href":"/en/developer-kit"}]},{"header":"Отзывы пользователей / Wall of Love","items":[{"label":"Отзывы пользователей (на китайском)","href":"/wall-of-love"},{"label":"Wall of Love (EN)","href":"/en/wall-of-love"}]}]},"navbar":{"links":[{"href":"https://api.apiyi.com","label":"Главная"},{"href":"https://imagen.apiyi.com","label":"Генерация изображений"},{"href":"https://icover.ai","label":"Генерация видео"}],"primary":{"type":"button","label":"Консоль","href":"https://api.apiyi.com/account/profile"}},"tabs":[{"tab":"Главная","icon":"house","pages":[{"title":"Главная","href":"/ru"}]},{"tab":"Сценарии использования","icon":"layout-grid","pages":[{"title":"Сценарии использования","href":"/ru/scenarios"}]},{"tab":"FAQ","icon":"circle-question-mark","groups":[{"group":"Обзор","pages":[{"title":"Обзор часто задаваемых вопросов","sidebarTitle":"Часто задаваемые вопросы","icon":"circle-question-mark","href":"/ru/faq"}]},{"group":"Возможности сайта","icon":"compass","pages":[{"title":"Tokens \u0026 Группы","icon":"key","href":"/ru/faq/token-and-groups"},{"title":"Что такое группа? Объяснение User Group и Token Group","icon":"layers","href":"/ru/faq/groups-explained"},{"title":"Чем отличаются группы CodexReverse, ClaudeCode и по умолчанию?","icon":"code","href":"/ru/faq/codex-claudecode-default-groups"},{"title":"Есть ли интеграция одним кликом?","icon":"plug","href":"/ru/faq/one-click-integration"}]},{"group":"Tokens и журналы","icon":"key","pages":[{"title":"В журнале указано, что вызов завершился и был тарифицирован, но мой клиент так и не получил ответ — как это отладить?","icon":"stethoscope","href":"/ru/faq/log-duration-vs-client-wait"},{"title":"Почему я не могу использовать некоторые модели?","icon":"lock","href":"/ru/faq/model-availability"},{"title":"Что такое персональный token доступа и как заменить системный token?","icon":"key-round","href":"/ru/faq/personal-access-token"},{"title":"Как создать KEY?","icon":"key","href":"/ru/faq/token-management"},{"title":"Нужно ли задавать доступные модели для token?","icon":"list-check","href":"/ru/faq/token-model-whitelist"},{"title":"Как безопасно управлять API-ключами?","icon":"shield-check","href":"/ru/faq/key-security-management"},{"title":"В чем разница между режимами тарификации token?","icon":"calculator","href":"/ru/faq/token-billing-modes"},{"title":"Как посмотреть мои записи вызовов?","icon":"file-text","href":"/ru/faq/call-logs"},{"title":"Где найти идентификатор запроса?","icon":"search","href":"/ru/faq/request-id-troubleshooting"},{"title":"Как читать суммы тарификации в логах?","icon":"receipt","href":"/ru/faq/log-billing-explained"},{"title":"Как долго хранятся журналы вызовов и когда они очищаются?","icon":"clock","href":"/ru/faq/log-retention-policy"},{"title":"Что нужно знать о настройках часового пояса в логах и экспорте данных?","icon":"globe","href":"/ru/faq/log-timezone-and-export"},{"title":"Могу ли я просматривать подробные логи в backend для устранения неполадок?","icon":"toggle-right","href":"/ru/faq/user-logs-control"},{"title":"Как расследовать неожиданное использование API Key?","icon":"key","href":"/ru/faq/troubleshoot-key-usage"}]},{"group":"Корпоративные услуги","icon":"building-2","pages":[{"title":"Что такое Enterprise-группа? Когда следует ее использовать?","icon":"building-2","href":"/ru/faq/enterprise-group-vertex-fallback"},{"title":"Есть ли более быстрый или корпоративный маршрут для генерации изображений?","icon":"route","href":"/ru/faq/image-generation-fast-enterprise-route"},{"title":"Надёжен ли корпоративный сервис APIYI? Подлинны ли модели?","icon":"badge-check","href":"/ru/faq/enterprise-trust"},{"title":"В чем разница между корпоративными и индивидуальными пользователями?","icon":"building-2","href":"/ru/faq/enterprise-vs-individual"},{"title":"Как корпоративным клиентам пополнять баланс?","icon":"landmark","href":"/ru/faq/enterprise-recharge"},{"title":"Как университетским клиентам оформить возмещение без лишних хлопот?","icon":"graduation-cap","href":"/ru/faq/university-reimbursement"},{"title":"Предлагает ли APIYI SLA-гарантии?","icon":"shield-check","href":"/ru/faq/sla-guarantee"},{"title":"Нужна ли мини-программе Agent регистрация алгоритма?","icon":"file-check","href":"/ru/faq/agent-miniapp-algorithm-filing"},{"title":"Как обеспечить соответствие требованиям для продукта, ориентированного на Китай, при использовании зарубежных моделей?","icon":"scale","href":"/ru/faq/overseas-model-compliance"}]},{"group":"Оплата и безопасность","icon":"shield","pages":[{"title":"Что означает суффикс -c в названиях model?","icon":"tag","href":"/ru/faq/model-name-suffix-c"},{"title":"Цены совпадают с официальными тарифами — зачем покупать у APIYI?","icon":"badge-percent","href":"/ru/faq/official-pricing-advantages"},{"title":"Почему APIYI может стоить ниже официальных тарифов?","icon":"trending-down","href":"/ru/faq/why-cheaper-than-official"},{"title":"Что означает модельный 'множитель'?","icon":"calculator","href":"/ru/faq/model-multiplier"},{"title":"Сколько вычислительных ресурсов дают 100 RMB?","icon":"calculator","href":"/ru/faq/rmb-to-computing-power"},{"title":"Что такое механизм предварительного списания для API-вызовов?","icon":"calculator","href":"/ru/faq/pre-deduction-quota"},{"title":"Поддерживает ли APIYI тарификацию кэша?","icon":"database","href":"/ru/faq/cache-billing"},{"title":"Какие способы оплаты поддерживает APIYI?","icon":"credit-card","href":"/ru/faq/payment-methods"},{"title":"Какие акции по пополнению доступны?","icon":"gift","href":"/ru/faq/recharge-promotions"},{"title":"Истекает ли срок действия моего баланса APIYI? Каков срок действия?","icon":"hourglass","href":"/ru/faq/balance-validity-period"},{"title":"Как настроить оповещения о балансе?","icon":"bell","href":"/ru/faq/balance-alerts"},{"title":"Почему я не могу отправлять запросы при оставшемся балансе?","icon":"credit-card","href":"/ru/faq/balance-insufficient"},{"title":"Что делать, если сумма счета меньше $100?","icon":"receipt","href":"/ru/faq/invoice-minimum-amount"},{"title":"Я указал неверные данные в счёте. Можно ли перевыпустить счёт?","icon":"receipt","href":"/ru/faq/invoice-reissue"},{"title":"Какова политика возврата средств APIYI?","icon":"receipt","href":"/ru/faq/refund-policy"},{"title":"Как подать заявку на партнерство агента? Могу ли я получать возврат, приглашая друзей?","icon":"users","href":"/ru/faq/referral-program"},{"title":"Как обеспечивается безопасность контента и соблюдение требований?","icon":"shield-check","href":"/ru/faq/content-safety"},{"title":"Как APIYI обеспечивает безопасность данных?","icon":"shield","href":"/ru/faq/data-security"}]},{"group":"Сеть и подключение","icon":"wifi","pages":[{"title":"Как избежать тайм-аутов API?","icon":"timer","href":"/ru/faq/timeout-configuration"},{"title":"Нужен ли мне прокси для использования API?","icon":"wifi","href":"/ru/faq/network-proxy"},{"title":"Python выдаёт SSLEOFError, но curl работает?","icon":"shield-alert","href":"/ru/faq/openssl-pq-handshake-eof"},{"title":"Где находятся серверы APIYI? Какой сервер мне выбрать?","icon":"server","href":"/ru/faq/server-location"},{"title":"Медленное скачивание изображений/видео из CDN или таймаут — что делать?","description":"Запрос к API изображений выполнен успешно, но скачивание по полученному URL идет медленно или завершается ошибкой Read timed out? Команды для самодиагностики (включая Windows), надежный шаблон скачивания и данные, которые необходимо нам отправить.","icon":"gauge","href":"/ru/faq/cdn-download-slow"},{"title":"Является ли http тем же самым, что и HTTP/1.1?","icon":"network","href":"/ru/faq/http-vs-http11"},{"title":"Как снизить задержку API генерации изображений?","description":"Рекомендации по сетевой оптимизации для генерации изображений в больших объемах, включая версию клиентского протокола, повторное использование соединений и настройки таймаутов.","icon":"gauge","href":"/ru/faq/image-api-network-latency-optimization"},{"title":"Веб-сайт или API возвращает 502 — что мне делать?","icon":"refresh-cw","href":"/ru/faq/website-502-error"},{"title":"Скрипт получает 502, но в журналах вызовов ничего нет?","icon":"unplug","href":"/ru/faq/proxy-empty-502"},{"title":"Запросы на генерацию изображений обрываются примерно через 90 секунд при работе через прокси?","icon":"unplug","href":"/ru/faq/proxy-idle-timeout-disconnect"},{"title":"Запрос на генерацию изображения зависает без результата, но в журнале указана ошибка записи?","icon":"hourglass","href":"/ru/faq/image-direct-large-response-stall"}]},{"group":"Аккаунт и вход","icon":"user","pages":[{"title":"Как обеспечить безопасность аккаунта? Зачем привязывать 2FA и Passkey?","icon":"shield-check","href":"/ru/faq/account-security-2fa-passkey"},{"title":"Какие почтовые провайдеры поддерживает APIYI для регистрации?","icon":"mail","href":"/ru/faq/email-registration"},{"title":"Как войти с помощью Passkey?","icon":"fingerprint-pattern","href":"/ru/faq/passkey-login"},{"title":"Вход через GitHub показывает «Учетная запись уже привязана»?","icon":"github","href":"/ru/faq/github-bindng-bindng-error"},{"title":"Что делать, если вы забыли пароль?","icon":"lock","href":"/ru/faq/forgot-password"},{"title":"Почему мой API Key недействителен?","icon":"key","href":"/ru/faq/invalid-api-key"},{"title":"Как удалить учетную запись?","icon":"trash","href":"/ru/faq/account-deletion"}]}]},{"tab":"Обновления в реальном времени","icon":"activity","pages":[{"title":"Обновления в реальном времени","href":"/ru/live"}]},{"tab":"Объявления","icon":"megaphone","pages":[{"title":"Объявления","href":"/ru/changelog"}]},{"tab":"Акции","icon":"gift","pages":[{"title":"Акции","href":"/ru/faq/recharge-promotions"}]},{"tab":"Цены на модели","icon":"circle-dollar-sign","pages":[{"title":"Цены на модели","href":"/ru/models"}]}]}]},"basePath":"","title":"Является ли http тем же самым, что и HTTP/1.1? - API易文档中心","buildId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","deploymentId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","dynamics":["10e4515597"],"chunks":["BannerMarkdown-DV3Oq1fY.js","dist-C-XZBk9h.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","clsx-D3Isdib3.js","html-void-elements-mCSPHezU.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js"]}