Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

shepherd-plugin-interfaces

Package Overview
Dependencies
Maintainers
1
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

shepherd-plugin-interfaces - npm Package Compare versions

Comparing version 0.0.2 to 0.1.0

17

index.ts
export interface FilterResult {
flagged: boolean
valid_data: boolean | undefined
scores?: string // just something to query when detection goes wrong?
flagged: boolean // main output: whether the image is filtereed or not
scores?: string // optional plugin scoring
}
/* Feedback error types to the host app. Host may process image and try submitting to plugin again. */
export interface FilterErrorResult {
flagged: undefined
data_reason: 'oversized' | 'partial' | 'unsupported' | 'corrupt' | 'corrupt-maybe' | (string & {})
err_message?: string // might help plugin dev?
data_reason:
'oversized' // oversized compressed png files that cannot be opened by most image libraries.
| 'partial' // partial image that library cannnot open
| 'unsupported' // unsupported file type (your plugin is expected to handle bmp/jpeg/png/gif at a minimum)
| 'corrupt' // image data is corrupt
| 'corrupt-maybe' // image data is corrupt, but can be displayed by a browser
| (string & {})
err_message?: string // optional error message
}

@@ -13,0 +18,0 @@

{
"name": "shepherd-plugin-interfaces",
"version": "0.0.2",
"version": "0.1.0",
"description": "",

@@ -12,3 +12,4 @@ "main": "index.ts",

"author": "Ros McMahon <rosmcmahon@gmail.com>",
"license": "GPL-3.0"
"license": "GPL-3.0",
"homepage": "https://github.com/shepherd-media-classifier/shepherd#shepherd-plugin-interfaces"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc