Skip to content

Commit

Permalink
feat: OpenAPI spec update via Stainless API (#1555)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] authored and stainless-bot committed Mar 13, 2024
1 parent 9acf8f3 commit 4252901
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion page_shield/script.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ func (r *ScriptService) Get(ctx context.Context, scriptID string, query ScriptGe
type PageShieldScript struct {
ID interface{} `json:"id"`
AddedAt interface{} `json:"added_at"`
DataflowScore interface{} `json:"dataflow_score"`
DomainReportedMalicious interface{} `json:"domain_reported_malicious"`
FetchedAt interface{} `json:"fetched_at"`
FirstPageURL interface{} `json:"first_page_url"`
Expand All @@ -64,6 +65,7 @@ type PageShieldScript struct {
Host interface{} `json:"host"`
JsIntegrityScore interface{} `json:"js_integrity_score"`
LastSeenAt interface{} `json:"last_seen_at"`
ObfuscationScore interface{} `json:"obfuscation_score"`
PageURLs interface{} `json:"page_urls"`
URL interface{} `json:"url"`
URLContainsCdnCgiPath interface{} `json:"url_contains_cdn_cgi_path"`
Expand All @@ -75,6 +77,7 @@ type PageShieldScript struct {
type pageShieldScriptJSON struct {
ID apijson.Field
AddedAt apijson.Field
DataflowScore apijson.Field
DomainReportedMalicious apijson.Field
FetchedAt apijson.Field
FirstPageURL apijson.Field
Expand All @@ -83,6 +86,7 @@ type pageShieldScriptJSON struct {
Host apijson.Field
JsIntegrityScore apijson.Field
LastSeenAt apijson.Field
ObfuscationScore apijson.Field
PageURLs apijson.Field
URL apijson.Field
URLContainsCdnCgiPath apijson.Field
Expand All @@ -101,6 +105,7 @@ func (r pageShieldScriptJSON) RawJSON() string {
type ScriptGetResponse struct {
ID interface{} `json:"id"`
AddedAt interface{} `json:"added_at"`
DataflowScore interface{} `json:"dataflow_score"`
DomainReportedMalicious interface{} `json:"domain_reported_malicious"`
FetchedAt interface{} `json:"fetched_at"`
FirstPageURL interface{} `json:"first_page_url"`
Expand All @@ -109,6 +114,7 @@ type ScriptGetResponse struct {
Host interface{} `json:"host"`
JsIntegrityScore interface{} `json:"js_integrity_score"`
LastSeenAt interface{} `json:"last_seen_at"`
ObfuscationScore interface{} `json:"obfuscation_score"`
PageURLs interface{} `json:"page_urls"`
URL interface{} `json:"url"`
URLContainsCdnCgiPath interface{} `json:"url_contains_cdn_cgi_path"`
Expand All @@ -121,6 +127,7 @@ type ScriptGetResponse struct {
type scriptGetResponseJSON struct {
ID apijson.Field
AddedAt apijson.Field
DataflowScore apijson.Field
DomainReportedMalicious apijson.Field
FetchedAt apijson.Field
FirstPageURL apijson.Field
Expand All @@ -129,6 +136,7 @@ type scriptGetResponseJSON struct {
Host apijson.Field
JsIntegrityScore apijson.Field
LastSeenAt apijson.Field
ObfuscationScore apijson.Field
PageURLs apijson.Field
URL apijson.Field
URLContainsCdnCgiPath apijson.Field
Expand All @@ -147,21 +155,27 @@ func (r scriptGetResponseJSON) RawJSON() string {

// The version of the analyzed script.
type ScriptGetResponseVersion struct {
// The dataflow score of the JavaScript content.
DataflowScore int64 `json:"dataflow_score,nullable"`
// The timestamp of when the script was last fetched.
FetchedAt string `json:"fetched_at,nullable"`
// The computed hash of the analyzed script.
Hash string `json:"hash,nullable"`
// The integrity score of the JavaScript content.
JsIntegrityScore int64 `json:"js_integrity_score,nullable"`
JsIntegrityScore int64 `json:"js_integrity_score,nullable"`
// The obfuscation score of the JavaScript content.
ObfuscationScore int64 `json:"obfuscation_score,nullable"`
JSON scriptGetResponseVersionJSON `json:"-"`
}

// scriptGetResponseVersionJSON contains the JSON metadata for the struct
// [ScriptGetResponseVersion]
type scriptGetResponseVersionJSON struct {
DataflowScore apijson.Field
FetchedAt apijson.Field
Hash apijson.Field
JsIntegrityScore apijson.Field
ObfuscationScore apijson.Field
raw string
ExtraFields map[string]apijson.Field
}
Expand Down

0 comments on commit 4252901

Please sign in to comment.