diff --git a/pkg/api/event_converters.go b/pkg/api/event_converters.go index d2ee2cee..00a6c4d3 100644 --- a/pkg/api/event_converters.go +++ b/pkg/api/event_converters.go @@ -628,8 +628,13 @@ func (h *Handler) convertAction(ctx context.Context, viewer *tongo.AccountID, a Bidder: convertAccountAddress(a.AuctionBid.Bidder, h.addressBook), Auction: convertAccountAddress(a.AuctionBid.Auction, h.addressBook), }) - if a.AuctionBid.Nft.CollectionAddress != nil && *a.AuctionBid.Nft.CollectionAddress == references.RootTelegram { + switch *a.AuctionBid.Nft.CollectionAddress { + case references.RootTelegram: action.AuctionBid.Value.AuctionType = oas.AuctionBidActionAuctionTypeDNSTg + case references.TelegramNumbers: + action.AuctionBid.Value.AuctionType = oas.AuctionBidActionAuctionTypeNUMBERTg + case references.RootDotTon: + action.AuctionBid.Value.AuctionType = oas.AuctionBidActionAuctionTypeDNSTon } action.SimplePreview = oas.ActionSimplePreview{ Name: "Auction bid", diff --git a/pkg/references/dns.go b/pkg/references/dns.go index de2a5442..ffda0366 100644 --- a/pkg/references/dns.go +++ b/pkg/references/dns.go @@ -1,13 +1,16 @@ package references -import "github.com/tonkeeper/tongo" +import ( + "github.com/tonkeeper/tongo" + "github.com/tonkeeper/tongo/ton" +) -var RootDotTon = tongo.MustParseAccountID("0:b774d95eb20543f186c06b371ab88ad704f7e256130caf96189368a7d0cb6ccf") +var RootDotTon = ton.MustParseAccountID("0:b774d95eb20543f186c06b371ab88ad704f7e256130caf96189368a7d0cb6ccf") var DomainSuffixes = map[tongo.AccountID]string{ RootDotTon: ".ton", RootTelegram: "", //telegram use full domain - tongo.MustParseAccountID("0:d9255340783403c635169d00aaaaaf2ab85fbb5d32c707b39a42157b7c347440"): ".dolboeb.t.me", + ton.MustParseAccountID("0:d9255340783403c635169d00aaaaaf2ab85fbb5d32c707b39a42157b7c347440"): ".dolboeb.t.me", } // use for checking ton-connect proofs diff --git a/pkg/references/telegram.go b/pkg/references/telegram.go index a82d274b..24436db1 100644 --- a/pkg/references/telegram.go +++ b/pkg/references/telegram.go @@ -1,5 +1,8 @@ package references -import "github.com/tonkeeper/tongo" +import ( + "github.com/tonkeeper/tongo/ton" +) -var RootTelegram = tongo.MustParseAccountID("EQCA14o1-VWhS2efqoh_9M1b_A9DtKTuoqfmkn83AbJzwnPi") +var RootTelegram = ton.MustParseAccountID("EQCA14o1-VWhS2efqoh_9M1b_A9DtKTuoqfmkn83AbJzwnPi") +var TelegramNumbers = ton.MustParseAccountID("EQAOQdwdw8kGftJCSFgOErM1mBjYPe4DBPq8-AhF6vr9si5N")