forked from
tangled.org/core
fork
Configure Feed
Select the types of activity you want to include in your feed.
Monorepo for Tangled
fork
Configure Feed
Select the types of activity you want to include in your feed.
1package models
2
3import (
4 "fmt"
5 "time"
6
7 "github.com/bluesky-social/indigo/atproto/syntax"
8 "github.com/go-git/go-git/v5/plumbing"
9 "github.com/ipfs/go-cid"
10 "tangled.org/core/api/tangled"
11)
12
13type Artifact struct {
14 Id uint64
15 Did string
16 Rkey string
17
18 RepoAt syntax.ATURI
19 Tag plumbing.Hash
20 CreatedAt time.Time
21
22 BlobCid cid.Cid
23 Name string
24 Size uint64
25 MimeType string
26}
27
28func (a *Artifact) ArtifactAt() syntax.ATURI {
29 return syntax.ATURI(fmt.Sprintf("at://%s/%s/%s", a.Did, tangled.RepoArtifactNSID, a.Rkey))
30}