delibird: github.com/purpleworks/delibird Index | Files | Directories

package delibird

import "github.com/purpleworks/delibird"

Package delibird is opensource shipment tracking library

Index

Package Files

constants.go doc.go model.go

Constants

const (
    NoCode           string = "NO_CODE_AVAILABLE"
    NoTrackingInfo   string = "NO_TRACKING_INFO"
    ParseError       string = "PARSE_ERROR"
    RequestPageError string = "REQUEST_PAGE_ERROR"
)

type ApiError Uses

type ApiError struct {
    Code    string
    Message string
}

Error json model

func NewApiError Uses

func NewApiError(code, message string) *ApiError

NewApiError creates ApiError object

func (ApiError) String Uses

func (e ApiError) String() string

String() implement

type History Uses

type History struct {
    Area       string         `json:"area"`
    Tel        string         `json:"tel,omitempty"`
    Date       int64          `json:"date"`
    DateText   string         `json:"date_text"`
    StatusCode TrackingStatus `json:"status_code"`
    StatusText string         `json:"status_text"`
}

type Track Uses

type Track struct {
    TrackingNumber string         `json:"tracking_number"`
    CompanyCode    string         `json:"company_code"`
    CompanyName    string         `json:"company_name"`
    Sender         string         `json:"sender"`
    Receiver       string         `json:"receiver"`
    Signer         string         `json:"signer"`
    StatusCode     TrackingStatus `json:"status_code"`
    StatusText     string         `json:"status_text"`
    History        []History      `json:"history"`
}

type TrackingStatus Uses

type TrackingStatus int
const (
    // 알수 없음
    UnknownStatus TrackingStatus = -1
    // 접수 대기
    Pending TrackingStatus = 1
    // 영업점 접수 (SM입고)
    Ready TrackingStatus = 2
    // 집화처리
    PickupComplete TrackingStatus = 3
    // 간선상차 / 물건 실음 / 중간 집화지 출발
    Loading TrackingStatus = 4
    // 간선하차 / 분류 / 중간 집화지 도착
    Unloading TrackingStatus = 5
    // 배송출발
    DeleveryStart TrackingStatus = 51
    // 배송완료
    DeleveryComplete TrackingStatus = 91
    // 미배달
    DoNotDelevery TrackingStatus = 99
)

Directories

PathSynopsis
couriers
server

Package delibird imports 1 packages (graph) and is imported by 2 packages. Updated 2017-04-21. Refresh now. Tools for package owners.