Skip to content

banovo/go-orocrm-wsse

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

go-orocrm-wsse GoDoc Build Status Go Report Card Software License Code Climate

Go WSSE transport (http.RoundTripper)

Usage

As RoundTripper

import (
	wsse "github.com/banovo/go-orocrm-wsse"
)

func main() {
	req, err := http.NewRequest(http.MethodGet, url, nil)
	t := wsse.NewTransport("my-user", "my-password-or-api-key")
	resp, err := t.RoundTrip(req)
	// do whatever you want
}

X-WSSE Header string only

import (
	wsse "github.com/banovo/go-orocrm-wsse"
)

func main() {
	fmt.Println(wsse.CreateHeader("my-user", "my-password-or-api-key"))
}

Difference to the forked package

This is an update of motemen's package. We avoid binary data and changed the date to ISO 8601. We do this because php and orocrm and the corresponding package and EscapeWSSEAuthenticationBundle seem to have problems with the orginal data.

Thanks

Special thanks to @motemen and his wsse package we (needed) to fork from.