bing

package
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 17, 2024 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ToneMap = map[string]string{
		"Creative": "h3imaginative",
		"Balanced": "galileo",
		"Precise":  "h3precise",
	}
	DefaultTone    = "Creative"
	DefaultCookies = []string{
		"SRCHD=AF=NOFORM",
		"PPLState=1",
		"KievRPSSecAuth=",
		"SUID=",
		"SRCHUSR=",
	}
	DefaultUserAgent = "" /* 129-byte string literal not displayed */
	DefaultHeaders   = http.Header{
		"accept":                      {"*/*"},
		"accept-language":             {"en-US,en;q=0.9"},
		"cache-control":               {"max-age=0"},
		"sec-ch-ua":                   {`"Chromium";v="110", "Not A(Brand";v="24", "Microsoft Edge";v="110"`},
		"sec-ch-ua-arch":              {`"x86"`},
		"sec-ch-ua-bitness":           {`"64"`},
		"sec-ch-ua-full-version":      {`"110.0.1587.69"`},
		"sec-ch-ua-full-version-list": {`"Chromium";v="110.0.5481.192", "Not A(Brand";v="24.0.0.0", "Microsoft Edge";v="110.0.1587.69"`},
		"sec-ch-ua-mobile":            {"?0"},
		"sec-ch-ua-model":             {`""`},
		"sec-ch-ua-platform":          {`"Windows"`},
		"sec-ch-ua-platform-version":  {`"15.0.0"`},
		"sec-fetch-dest":              {"document"},
		"sec-fetch-mode":              {"navigate"},
		"sec-fetch-site":              {"none"},
		"sec-fetch-user":              {"?1"},
		"upgrade-insecure-requests":   {"1"},
		"user-agent":                  {DefaultUserAgent},
		"x-edge-shopping-flag":        {"1"},
	}
	OptionDefaultSets = []string{
		"nlu_direct_response_filter",
		"deepleo",
		"disable_emoji_spoken_text",
		"responsible_ai_policy_235",
		"enablemm",
		"dv3sugg",
		"iyxapbing",
		"iycapbing",
		"clgalileo",
		"gencontentv3",
		"eredirecturl",
		"fluxsrtrunc",
		"fluxtrunc",
		"fluxv1",
		"rai278",
		"replaceurl",
		"nojbfedge",
		"bcechat",
		"dlgpt4t"}
	AllowedMessageTypes = []string{
		"ActionRequest",
		"Chat",
		"Context",
		"Progress",
		"SemanticSerp",
		"GenerateContentQuery",
		"SearchQuery",
		"RenderCardRequest",
		"InvokeAction",
		"ConfirmationCard",
		"InternalSearchQuery",
		"InternalSearchResult",
		"Disengaged",
		"InternalLoaderMessage",
		"RenderContentRequest",
		"AdsQuery"}
	SliceIds = []string{
		"abv2",
		"srdicton",
		"convcssclick",
		"stylewv2",
		"contctxp2tf",
		"802fluxv1pc_a",
		"806log2sphs0",
		"727savemem",
		"277teditgnds0",
		"207hlthgrds0",
		"inlineta",
		"inlinetadisc"}

	WsDelimiterByte          byte = 30
	OriginUrl                     = "https://www.bing.com"
	ListConversationApiUrl        = "https://www.bing.com/turing/conversation/chats"
	CreateConversationApiUrl      = "https://www.bing.com/turing/conversation/create?bundleVersion=1.1199.4"
	DeleteConversationApiUrl      = "https://sydney.bing.com/sydney/DeleteSingleConversation"
	ImageUploadRefererUrl         = "https://www.bing.com/search?q=Bing+AI&showconv=1&FORM=hpcodx"
	ImageUrl                      = "https://www.bing.com/images/blob?bcid="
	ImageUploadApiUrl             = "https://www.bing.com/images/kblob"
	WssScheme                     = "wss"
	WssHost                       = "sydney.bing.com"
	WssPath                       = "/sydney/ChatHub"
)

Functions

func DoCreateConversation

func DoCreateConversation() func(*fhblade.Context) error

func DoDeleteConversation

func DoDeleteConversation() func(*fhblade.Context) error

func DoListConversation

func DoListConversation() func(*fhblade.Context) error

func DoSendMessage

func DoSendMessage() func(*fhblade.Context) error

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL