Documentation ¶
Overview ¶
@openapi 3.0.0
@openapi 3.0.0
Index ¶
- func BulkUploadEmailsForVerification(services *service.Services) gin.HandlerFunc
- func CallApiValidateEmail(ctx context.Context, services *service.Services, emailAddress string, ...) (*validationmodel.ValidateEmailResponse, error)
- func DownloadBulkEmailVerificationResults(services *service.Services) gin.HandlerFunc
- func GetBulkEmailVerificationResults(services *service.Services) gin.HandlerFunc
- func IpIntelligence(services *service.Services) gin.HandlerFunc
- func VerifyEmailAddress(services *service.Services) gin.HandlerFunc
- type BulkResultsDetails
- type BulkResultsResponse
- type BulkUploadResponse
- type EmailVerificationRecord
- type EmailVerificationResponse
- type EmailVerificationRisk
- type EmailVerificationSyntax
- type IpIntelligenceGeolocation
- type IpIntelligenceNetwork
- type IpIntelligenceOrganization
- type IpIntelligenceRecord
- type IpIntelligenceResponse
- type IpIntelligenceThreats
- type IpIntelligenceTimeZone
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BulkUploadEmailsForVerification ¶
func BulkUploadEmailsForVerification(services *service.Services) gin.HandlerFunc
@Summary Upload emails for bulk verification @Description Initiates bulk verification process for emails from CSV file @Tags Email Verification @Accept multipart/form-data @Produce json @Param file formData file true "CSV file containing email addresses" @Param emailColumn formData string false "CSV column containing emails" default(first column) @Param verifyCatchAll formData bool false "Verify catch-all domains" default(true) @Success 200 {object} BulkUploadResponse "Bulk verification initiated" @Failure 400 {object} rest.ErrorResponse "Invalid file format or missing parameters" @Failure 401 {object} rest.ErrorResponse "Unauthorized - Missing or invalid API key" @Failure 500 {object} rest.ErrorResponse "Internal server error" @Router /verify/v1/email/bulk [post] @Security ApiKeyAuth
func CallApiValidateEmail ¶
func CallApiValidateEmail(ctx context.Context, services *service.Services, emailAddress string, verifyCatchAll bool) (*validationmodel.ValidateEmailResponse, error)
func DownloadBulkEmailVerificationResults ¶
func DownloadBulkEmailVerificationResults(services *service.Services) gin.HandlerFunc
@Summary Download bulk verification results @Description Downloads CSV file containing detailed verification results @Tags Email Verification @Accept json @Produce text/csv @Param requestId path string true "Bulk verification job ID" format(uuid) @Success 200 {file} csv "CSV file containing verification results" @Failure 400 {object} rest.ErrorResponse "Invalid job ID" @Failure 401 {object} rest.ErrorResponse "Unauthorized - Missing or invalid API key" @Failure 404 {object} rest.ErrorResponse "Results not found" @Failure 500 {object} rest.ErrorResponse "Internal server error" @Router /verify/v1/email/bulk/results/{requestId}/download [get] @Security ApiKeyAuth
func GetBulkEmailVerificationResults ¶
func GetBulkEmailVerificationResults(services *service.Services) gin.HandlerFunc
@Summary Get bulk verification results @Description Retrieves results or status of bulk verification job @Tags Email Verification @Accept json @Produce json @Param requestId path string true "Bulk verification job ID" format(uuid) @Success 200 {object} BulkResultsResponse "Verification results or status" @Failure 400 {object} rest.ErrorResponse "Invalid job ID" @Failure 401 {object} rest.ErrorResponse "Unauthorized - Missing or invalid API key" @Failure 404 {object} rest.ErrorResponse "Job not found" @Failure 500 {object} rest.ErrorResponse "Internal server error" @Router /verify/v1/email/bulk/results/{requestId} [get] @Security ApiKeyAuth
func IpIntelligence ¶
func IpIntelligence(services *service.Services) gin.HandlerFunc
@Summary Get IP intelligence data @Description Retrieves comprehensive information about an IP address including threats, geolocation, and network details @Tags IP Intelligence @Accept json @Produce json @Param address query string true "IP address to analyze" pattern(^(?:[0-9]{1,3}\.){3}[0-9]{1,3}$) @Success 200 {object} IpIntelligenceResponse "IP intelligence data retrieved successfully" @Failure 400 {object} rest.ErrorResponse "Invalid IP address format" @Failure 401 {object} rest.ErrorResponse "Unauthorized - Missing or invalid API key" @Failure 500 {object} rest.ErrorResponse "Internal server error" @Router /verify/v1/ip [get] @Security ApiKeyAuth
func VerifyEmailAddress ¶
func VerifyEmailAddress(services *service.Services) gin.HandlerFunc
@Summary Verify single email address @Description Performs comprehensive validation of a single email address @Tags Email Verification @Accept json @Produce json @Param address query string true "Email address to verify" format(email) @Param verifyCatchAll query bool false "Verify catch-all domain" default(true) @Success 200 {object} EmailVerificationResponse "Email verification results" @Failure 400 {object} rest.ErrorResponse "Invalid email format or missing parameters" @Failure 401 {object} rest.ErrorResponse "Unauthorized - Missing or invalid API key" @Failure 500 {object} rest.ErrorResponse "Internal server error" @Router /verify/v1/email [get] @Security ApiKeyAuth
Types ¶
type BulkResultsDetails ¶
type BulkResultsDetails struct { // Total number of emails processed // required: true // minimum: 0 TotalEmails int `json:"totalEmails" example:"1000"` // Number of deliverable emails // required: true // minimum: 0 Deliverable int `json:"deliverable" example:"950"` // Number of undeliverable emails // required: true // minimum: 0 Undeliverable int `json:"undeliverable" example:"45"` // URL to download detailed results // required: true // format: uri DownloadURL string `` /* 129-byte string literal not displayed */ }
BulkResultsDetails represents detailed bulk verification results @Description Detailed statistics for bulk verification results
type BulkResultsResponse ¶
type BulkResultsResponse struct { // Unique job identifier // required: true // format: uuid JobID string `json:"jobId" example:"550e8400-e29b-41d4-a716-446655440000"` // Processing status // required: true // enum: processing,completed Status string `json:"status" example:"completed"` // Original filename // required: true FileName string `json:"fileName" example:"emails.csv"` // Progress message // required: true Message string `json:"message" example:"Completed 1000 of 1000 emails"` // Verification results if completed // required: false Results *BulkResultsDetails `json:"results,omitempty"` // Estimated completion timestamp // required: true EstimatedCompletionTs int64 `json:"estimatedCompletionTs" example:"1694030400"` }
BulkResultsResponse represents bulk verification results @Description Response containing bulk verification results or status
type BulkUploadResponse ¶
type BulkUploadResponse struct { // Status message // required: true Message string `json:"message" example:"File uploaded successfully"` // Unique job identifier // required: true // format: uuid JobID string `json:"jobId" example:"550e8400-e29b-41d4-a716-446655440000"` // URL to check verification results // required: true // format: uri ResultURL string `json:"resultUrl" example:"https://api.customeros.ai/verify/v1/email/bulk/results/550e8400-e29b-41d4-a716-446655440000"` // Estimated completion timestamp // required: true EstimatedCompletionTs float64 `json:"estimatedCompletionTs" example:"1694030400"` }
BulkUploadResponse represents bulk verification job initiation response @Description Response after initiating bulk email verification
type EmailVerificationRecord ¶
type EmailVerificationRecord struct { // Email address that was verified // required: true // format: email EmailAddress string `json:"emailAddress" example:"example@example.com"` // Deliverability status // required: true // enum: true,false,unknown Deliverable string `json:"deliverable" example:"true"` // Email service provider // required: false Provider string `json:"provider" example:"gmail"` // Security gateway provider // required: false SecureGatewayProvider string `json:"secureGatewayProvider" example:"Proofpoint"` // Indicates if email is considered risky // required: true IsRisky bool `json:"isRisky" example:"false"` // Indicates if domain is catch-all // required: true IsCatchAll bool `json:"isCatchAll" example:"false"` // Risk assessment details // required: true Risk EmailVerificationRisk `json:"risk"` // Syntax validation details // required: true Syntax EmailVerificationSyntax `json:"syntax"` // Alternative email address if available // required: false // format: email AlternateEmail string `json:"alternateEmail,omitempty" example:"alternate@example.com"` }
EmailVerificationRecord represents detailed email verification results @Description Detailed validation results for an email address
type EmailVerificationResponse ¶
type EmailVerificationResponse struct { // Inherits standard response fields enum.BaseResponse // Email verification details // required: true Email EmailVerificationRecord `json:"email,omitempty"` }
EmailVerificationResponse represents the email verification response @Description Response for single email verification including detailed validation results
type EmailVerificationRisk ¶
type EmailVerificationRisk struct { // Indicates if email is behind a firewall // required: true IsFirewalled bool `json:"isFirewalled" example:"false"` // Indicates if email is a role account // required: true IsRoleMailbox bool `json:"isRoleMailbox" example:"false"` // Indicates if email is system-generated // required: true IsSystemGenerated bool `json:"isSystemGenerated" example:"false"` // Indicates if email uses a free provider // required: true IsFreeProvider bool `json:"isFreeProvider" example:"true"` // Indicates if mailbox is full // required: true IsMailboxFull bool `json:"isMailboxFull" example:"false"` // Indicates if domain is primary // required: true IsPrimaryDomain bool `json:"isPrimaryDomain" example:"true"` }
EmailVerificationRisk represents risk assessment details @Description Risk factors associated with the email address
type EmailVerificationSyntax ¶
type EmailVerificationSyntax struct { // Indicates if email syntax is valid // required: true IsValid bool `json:"isValid" example:"true"` // Domain part of email // required: true Domain string `json:"domain" example:"example.com"` // Local part of email // required: true User string `json:"user" example:"example"` }
EmailVerificationSyntax represents syntax validation results @Description Email syntax validation details
type IpIntelligenceGeolocation ¶
type IpIntelligenceGeolocation struct { // City name // required: false City string `json:"city" example:"Berlin"` // Country name // required: true Country string `json:"country" example:"Germany"` // ISO 3166-1 alpha-2 country code // required: true // pattern: ^[A-Z]{2}$ CountryIso string `json:"countryIso" example:"DE"` // Indicates if country is in the European Union // required: true IsEuropeanUnion bool `json:"isEuropeanUnion" example:"true"` }
IpIntelligenceGeolocation represents geolocation data @Description Geographic location information for the IP address
type IpIntelligenceNetwork ¶
type IpIntelligenceNetwork struct { // Autonomous System Number // required: true // pattern: ^AS\d+$ ASN string `json:"asn" example:"AS12345"` // Network name // required: true Name string `json:"name" example:"ISP Name"` // Network domain // required: false Domain string `json:"domain" example:"isp.com"` // Network route (CIDR notation) // required: true // pattern: ^(\d{1,3}\.){3}\d{1,3}/\d{1,2}$ Route string `json:"route" example:"192.168.0.0/16"` // Network type // required: true // enum: business,hosting,isp,education,government Type string `json:"type" example:"business"` }
IpIntelligenceNetwork represents network data @Description Network information for the IP address
type IpIntelligenceOrganization ¶
type IpIntelligenceOrganization struct { // Organization name // required: false Name string `json:"name" example:"Company Name"` // Organization domain // required: false Domain string `json:"domain" example:"company.com"` // LinkedIn profile URL // required: false // format: uri LinkedIn string `json:"linkedin" example:"https://linkedin.com/company/company"` }
IpIntelligenceOrganization represents organization data @Description Organization information associated with the IP address
type IpIntelligenceRecord ¶
type IpIntelligenceRecord struct { // IP address being analyzed // required: true // pattern: ^(?:[0-9]{1,3}\.){3}[0-9]{1,3}$ IPAddress string `json:"ipAddress" example:"192.168.1.1"` // Threat intelligence information // required: true Threats IpIntelligenceThreats `json:"threats"` // Geolocation information // required: true Geolocation IpIntelligenceGeolocation `json:"geolocation"` // Timezone information // required: true TimeZone IpIntelligenceTimeZone `json:"time_zone"` // Network information // required: true Network IpIntelligenceNetwork `json:"network"` // Organization information // required: false Organization IpIntelligenceOrganization `json:"organization"` }
IpIntelligenceRecord represents detailed IP information @Description Comprehensive information about an IP address
type IpIntelligenceResponse ¶
type IpIntelligenceResponse struct { // Inherits standard response fields enum.BaseResponse // IP intelligence details // required: true IP IpIntelligenceRecord `json:"ip,omitempty"` }
IpIntelligenceResponse represents the IP intelligence response @Description Response containing IP intelligence data including threats, geolocation, and network information
type IpIntelligenceThreats ¶
type IpIntelligenceThreats struct { // Indicates if IP is a proxy // required: true IsProxy bool `json:"isProxy" example:"false"` // Indicates if IP is a VPN // required: true IsVpn bool `json:"isVpn" example:"false"` // Indicates if IP is a TOR exit node // required: true IsTor bool `json:"isTor" example:"false"` // Indicates if IP is unallocated // required: true IsUnallocated bool `json:"isUnallocated" example:"false"` // Indicates if IP belongs to a datacenter // required: true IsDatacenter bool `json:"isDatacenter" example:"false"` // Indicates if IP is a cloud relay // required: true IsCloudRelay bool `json:"isCloudRelay" example:"false"` // Indicates if IP belongs to a mobile network // required: true IsMobile bool `json:"isMobile" example:"false"` }
IpIntelligenceThreats represents threat intelligence data @Description Threat intelligence indicators for the IP address
type IpIntelligenceTimeZone ¶
type IpIntelligenceTimeZone struct { // IANA timezone name // required: true // example: Europe/Berlin Name string `json:"name"` // Timezone abbreviation // required: true // example: CET Abbr string `json:"abbr"` // UTC offset // required: true // pattern: ^[+-]\d{4}$ Offset string `json:"offset" example:"+0100"` // Indicates if daylight saving time is active // required: true IsDst bool `json:"is_dst" example:"true"` // Current time in the timezone // required: true // format: date-time CurrentTime time.Time `json:"current_time" example:"2024-09-10T14:00:00+01:00"` }
IpIntelligenceTimeZone represents timezone data @Description Timezone information for the IP address location