···11+// Code generated by indigo lexgen tool. DO NOT EDIT MANUALLY.
22+33+// Lexicon schema: community.lexicon.location.hthree
44+55+package communitylexicon
66+77+// A physical location in the form of a H3 encoded location.
88+type LocationHthree struct {
99+ LexiconTypeID string `json:"$type,omitempty" cborgen:"$type,const=community.lexicon.location.hthree,omitempty"`
1010+ // name: The name of the location.
1111+ Name *string `json:"name,omitempty" cborgen:"name,omitempty"`
1212+ // value: The h3 encoded location.
1313+ Value string `json:"value" cborgen:"value"`
1414+}
···11+// Code generated by indigo lexgen tool. DO NOT EDIT MANUALLY.
22+33+// Lexicon schema: place.atwork.endorsement
44+55+package placeatwork
66+77+import (
88+ "encoding/json"
99+ "fmt"
1010+1111+ comatproto "github.com/bluesky-social/indigo/api/atproto"
1212+ lexutil "github.com/bluesky-social/indigo/lex/util"
1313+)
1414+1515+// A cryptographically-verified professional endorsement between two identities.
1616+type Endorsement struct {
1717+ LexiconTypeID string `json:"$type" cborgen:"$type,const=place.atwork.endorsement"`
1818+ // createdAt: Timestamp when the endorsement was created.
1919+ CreatedAt string `json:"createdAt" cborgen:"createdAt"`
2020+ // giver: The DID of the identity giving the endorsement.
2121+ Giver string `json:"giver" cborgen:"giver"`
2222+ // receiver: The DID of the identity receiving the endorsement.
2323+ Receiver string `json:"receiver" cborgen:"receiver"`
2424+ // signatures: Verified signatures from endorsement proofs (strong references).
2525+ Signatures []Endorsement_Signatures_Elem `json:"signatures,omitempty" cborgen:"signatures,omitempty"`
2626+ // text: The endorsement text content.
2727+ Text string `json:"text" cborgen:"text"`
2828+}
2929+3030+type Endorsement_Signatures_Elem struct {
3131+ RepoStrongRef *comatproto.RepoStrongRef
3232+}
3333+3434+func (t *Endorsement_Signatures_Elem) MarshalJSON() ([]byte, error) {
3535+ if t.RepoStrongRef != nil {
3636+ t.RepoStrongRef.LexiconTypeID = "com.atproto.repo.strongRef"
3737+ return json.Marshal(t.RepoStrongRef)
3838+ }
3939+ return nil, fmt.Errorf("can not marshal empty union as JSON")
4040+}
4141+4242+func (t *Endorsement_Signatures_Elem) UnmarshalJSON(b []byte) error {
4343+ typ, err := lexutil.TypeExtract(b)
4444+ if err != nil {
4545+ return err
4646+ }
4747+4848+ switch typ {
4949+ case "com.atproto.repo.strongRef":
5050+ t.RepoStrongRef = new(comatproto.RepoStrongRef)
5151+ return json.Unmarshal(b, t.RepoStrongRef)
5252+ default:
5353+ return nil
5454+ }
5555+}
+12
placeatwork/endorsementProof.go
···11+// Code generated by indigo lexgen tool. DO NOT EDIT MANUALLY.
22+33+// Lexicon schema: place.atwork.endorsementProof
44+55+package placeatwork
66+77+// A cryptographic proof record that validates an endorsement by containing the CID of the endorsement content.
88+type EndorsementProof struct {
99+ LexiconTypeID string `json:"$type" cborgen:"$type,const=place.atwork.endorsementProof"`
1010+ // cid: The CID (Content Identifier) of the endorsement content that this proof validates. The endorsement's signatures array references this proof record.
1111+ Cid string `json:"cid" cborgen:"cid"`
1212+}
+40
placeatwork/getListing.go
···11+// Code generated by indigo lexgen tool. DO NOT EDIT MANUALLY.
22+33+// Lexicon schema: place.atwork.getListing
44+55+package placeatwork
66+77+import (
88+ "context"
99+1010+ lexutil "github.com/bluesky-social/indigo/lex/util"
1111+)
1212+1313+// GetListing_Output is the output of a place.atwork.getListing call.
1414+type GetListing_Output struct {
1515+ // cid: CID of the listing record
1616+ Cid *string `json:"cid,omitempty" cborgen:"cid,omitempty"`
1717+ // uri: AT-URI of the listing
1818+ Uri string `json:"uri" cborgen:"uri"`
1919+ // value: The job listing record
2020+ Value Listing `json:"value" cborgen:"value"`
2121+}
2222+2323+// GetListing calls the XRPC method "place.atwork.getListing".
2424+//
2525+// # Get a single job listing by repo (DID) and record key
2626+//
2727+// repo: The DID of the repo (repository owner)
2828+// rkey: The record key (TID)
2929+func GetListing(ctx context.Context, c lexutil.LexClient, repo string, rkey string) (*GetListing_Output, error) {
3030+ var out GetListing_Output
3131+3232+ params := map[string]interface{}{}
3333+ params["repo"] = repo
3434+ params["rkey"] = rkey
3535+3636+ if err := c.LexDo(ctx, lexutil.Query, "", "place.atwork.getListing", params, nil, &out); err != nil {
3737+ return nil, err
3838+ }
3939+ return &out, nil
4040+}
+52
placeatwork/getListings.go
···11+// Code generated by indigo lexgen tool. DO NOT EDIT MANUALLY.
22+33+// Lexicon schema: place.atwork.getListings
44+55+package placeatwork
66+77+import (
88+ "context"
99+1010+ lexutil "github.com/bluesky-social/indigo/lex/util"
1111+)
1212+1313+// GetListings_Output is the output of a place.atwork.getListings call.
1414+type GetListings_Output struct {
1515+ Listings []GetListings_ListingRecord `json:"listings" cborgen:"listings"`
1616+}
1717+1818+// GetListings calls the XRPC method "place.atwork.getListings".
1919+//
2020+// # Get job listings, optionally filtered by tag or identity
2121+//
2222+// identity: Filter listings by creator DID (e.g., did:plc:abc123)
2323+// tag: Filter listings by hashtag
2424+func GetListings(ctx context.Context, c lexutil.LexClient, identity string, tag string) (*GetListings_Output, error) {
2525+ var out GetListings_Output
2626+2727+ params := map[string]interface{}{}
2828+ if identity != "" {
2929+ params["identity"] = identity
3030+ }
3131+ if tag != "" {
3232+ params["tag"] = tag
3333+ }
3434+3535+ if err := c.LexDo(ctx, lexutil.Query, "", "place.atwork.getListings", params, nil, &out); err != nil {
3636+ return nil, err
3737+ }
3838+ return &out, nil
3939+}
4040+4141+// GetListings_ListingRecord is a "listingRecord" in the place.atwork.getListings schema.
4242+//
4343+// A job listing record with metadata for strong references
4444+type GetListings_ListingRecord struct {
4545+ LexiconTypeID string `json:"$type,omitempty" cborgen:"$type,const=place.atwork.getListings#listingRecord,omitempty"`
4646+ // cid: CID of the listing record
4747+ Cid string `json:"cid" cborgen:"cid"`
4848+ // uri: AT-URI of the listing (at://did/place.atwork.listing/rkey)
4949+ Uri string `json:"uri" cborgen:"uri"`
5050+ // value: The full job listing record
5151+ Value *Listing `json:"value,omitempty" cborgen:"value,omitempty"`
5252+}
+62
placeatwork/listing.go
···11+// Code generated by indigo lexgen tool. DO NOT EDIT MANUALLY.
22+33+// Lexicon schema: place.atwork.listing
44+55+package placeatwork
66+77+import (
88+ "encoding/json"
99+ "fmt"
1010+1111+ appbsky "github.com/bluesky-social/indigo/api/bsky"
1212+ lexutil "github.com/bluesky-social/indigo/lex/util"
1313+ "tangled.org/bnewbold.net/atwork-cli/communitylexicon"
1414+)
1515+1616+// A job listing
1717+type Listing struct {
1818+ LexiconTypeID string `json:"$type" cborgen:"$type,const=place.atwork.listing"`
1919+ // applyLink: URL where applicants can apply for the job.
2020+ ApplyLink *string `json:"applyLink,omitempty" cborgen:"applyLink,omitempty"`
2121+ // banner: Larger horizontal image to display behind job listing view.
2222+ Banner *lexutil.LexBlob `json:"banner,omitempty" cborgen:"banner,omitempty"`
2323+ // description: The description of the job listing.
2424+ Description string `json:"description" cborgen:"description"`
2525+ // facets: Annotations of text (mentions, URLs, hashtags, etc).
2626+ Facets []appbsky.RichtextFacet `json:"facets,omitempty" cborgen:"facets,omitempty"`
2727+ // locations: Locations that are relevant to the job listing.
2828+ Locations []Listing_Locations_Elem `json:"locations,omitempty" cborgen:"locations,omitempty"`
2929+ // notAfter: Client-declared timestamp when the job listing expires.
3030+ NotAfter string `json:"notAfter" cborgen:"notAfter"`
3131+ // notBefore: Client-declared timestamp when the job listing becomes visible.
3232+ NotBefore string `json:"notBefore" cborgen:"notBefore"`
3333+ // title: The title of the job listing.
3434+ Title string `json:"title" cborgen:"title"`
3535+}
3636+3737+type Listing_Locations_Elem struct {
3838+ LocationHthree *communitylexicon.LocationHthree
3939+}
4040+4141+func (t *Listing_Locations_Elem) MarshalJSON() ([]byte, error) {
4242+ if t.LocationHthree != nil {
4343+ t.LocationHthree.LexiconTypeID = "community.lexicon.location.hthree"
4444+ return json.Marshal(t.LocationHthree)
4545+ }
4646+ return nil, fmt.Errorf("can not marshal empty union as JSON")
4747+}
4848+4949+func (t *Listing_Locations_Elem) UnmarshalJSON(b []byte) error {
5050+ typ, err := lexutil.TypeExtract(b)
5151+ if err != nil {
5252+ return err
5353+ }
5454+5555+ switch typ {
5656+ case "community.lexicon.location.hthree":
5757+ t.LocationHthree = new(communitylexicon.LocationHthree)
5858+ return json.Unmarshal(b, t.LocationHthree)
5959+ default:
6060+ return nil
6161+ }
6262+}
+31
placeatwork/profile.go
···11+// Code generated by indigo lexgen tool. DO NOT EDIT MANUALLY.
22+33+// Lexicon schema: place.atwork.profile
44+55+package placeatwork
66+77+import (
88+ appbsky "github.com/bluesky-social/indigo/api/bsky"
99+ lexutil "github.com/bluesky-social/indigo/lex/util"
1010+)
1111+1212+// A user profile for AT://Work.Place
1313+type Profile struct {
1414+ LexiconTypeID string `json:"$type" cborgen:"$type,const=place.atwork.profile"`
1515+ // avatar: Small image to be displayed next to job listings from account. AKA, 'profile picture'
1616+ Avatar *lexutil.LexBlob `json:"avatar,omitempty" cborgen:"avatar,omitempty"`
1717+ // banner: Larger horizontal image to display behind profile view.
1818+ Banner *lexutil.LexBlob `json:"banner,omitempty" cborgen:"banner,omitempty"`
1919+ // description: A free text description of the identity.
2020+ Description *string `json:"description,omitempty" cborgen:"description,omitempty"`
2121+ // displayName: The display name of the identity.
2222+ DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"`
2323+ // facets: Annotations of text (mentions, URLs, hashtags, etc) in the description.
2424+ Facets []appbsky.RichtextFacet `json:"facets,omitempty" cborgen:"facets,omitempty"`
2525+ // profile_host: The service used for profile links
2626+ Profile_host *string `json:"profile_host,omitempty" cborgen:"profile_host,omitempty"`
2727+ // resume: The identity's resume.
2828+ Resume *lexutil.LexBlob `json:"resume,omitempty" cborgen:"resume,omitempty"`
2929+ // status: The current status of the identity.
3030+ Status *string `json:"status,omitempty" cborgen:"status,omitempty"`
3131+}
+46
placeatwork/searchListings.go
···11+// Code generated by indigo lexgen tool. DO NOT EDIT MANUALLY.
22+33+// Lexicon schema: place.atwork.searchListings
44+55+package placeatwork
66+77+import (
88+ "context"
99+1010+ lexutil "github.com/bluesky-social/indigo/lex/util"
1111+)
1212+1313+// SearchListings_Output is the output of a place.atwork.searchListings call.
1414+type SearchListings_Output struct {
1515+ Listings []SearchListings_ListingRecord `json:"listings" cborgen:"listings"`
1616+}
1717+1818+// SearchListings calls the XRPC method "place.atwork.searchListings".
1919+//
2020+// # Search job listings using full-text query
2121+//
2222+// query: Search query string for full-text search
2323+func SearchListings(ctx context.Context, c lexutil.LexClient, query string) (*SearchListings_Output, error) {
2424+ var out SearchListings_Output
2525+2626+ params := map[string]interface{}{}
2727+ params["query"] = query
2828+2929+ if err := c.LexDo(ctx, lexutil.Query, "", "place.atwork.searchListings", params, nil, &out); err != nil {
3030+ return nil, err
3131+ }
3232+ return &out, nil
3333+}
3434+3535+// SearchListings_ListingRecord is a "listingRecord" in the place.atwork.searchListings schema.
3636+//
3737+// A job listing record with metadata for strong references
3838+type SearchListings_ListingRecord struct {
3939+ LexiconTypeID string `json:"$type,omitempty" cborgen:"$type,const=place.atwork.searchListings#listingRecord,omitempty"`
4040+ // cid: CID of the listing record
4141+ Cid string `json:"cid" cborgen:"cid"`
4242+ // uri: AT-URI of the listing (at://did/place.atwork.listing/rkey)
4343+ Uri string `json:"uri" cborgen:"uri"`
4444+ // value: The full job listing record
4545+ Value *Listing `json:"value,omitempty" cborgen:"value,omitempty"`
4646+}