2024-10-01 17:02:49 +02:00
|
|
|
package token
|
2024-09-30 09:58:08 -04:00
|
|
|
|
2024-10-01 14:25:07 +02:00
|
|
|
import (
|
|
|
|
|
"github.com/ipld/go-ipld-prime/datamodel"
|
|
|
|
|
|
2026-01-08 15:46:02 -05:00
|
|
|
"code.sonr.org/go/ucan/token/internal/envelope"
|
2024-10-01 14:25:07 +02:00
|
|
|
)
|
|
|
|
|
|
|
|
|
|
type Info = envelope.Info
|
|
|
|
|
|
|
|
|
|
// Inspect inspects the given token IPLD representation and extract some envelope facts.
|
|
|
|
|
func Inspect(node datamodel.Node) (Info, error) {
|
|
|
|
|
return envelope.Inspect(node)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// FindTag inspect the given token IPLD representation and extract the token tag.
|
|
|
|
|
func FindTag(node datamodel.Node) (string, error) {
|
|
|
|
|
return envelope.FindTag(node)
|
|
|
|
|
}
|