diff --git a/tools/cli/internal/openapi/errors/pathConflictError.go b/tools/cli/internal/openapi/errors/pathConflictError.go new file mode 100644 index 000000000..59fd5b8ae --- /dev/null +++ b/tools/cli/internal/openapi/errors/pathConflictError.go @@ -0,0 +1,11 @@ +package errors + +import "fmt" + +type PathConflictError struct { + Entry string +} + +func (e PathConflictError) Error() string { + return fmt.Sprintf("there was a conflict with the Path: %s", e.Entry) +} diff --git a/tools/cli/internal/openapi/openapi.go b/tools/cli/internal/openapi/openapi.go new file mode 100644 index 000000000..5bdb95939 --- /dev/null +++ b/tools/cli/internal/openapi/openapi.go @@ -0,0 +1,13 @@ +package openapi + +import ( + "github.com/tufin/oasdiff/load" +) + +type Merger interface { + MergeOpenAPISpecs([]string) (*load.SpecInfo, error) +} + +type Parser interface { + CreateOpenAPISpecFromPath(string) (*load.SpecInfo, error) +}