Skip to main content

Questions tagged [convert]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer
12 views

API for ETH to USD based on time and date

Does anyone know an API that will work based on any period of time. An API where I can put the year, month, day and time and it will give me the ETH to USD conversion at that moment?
hana's user avatar
  • 1
0 votes
0 answers
13 views

How to convert takerRate to readable value from 1inch API OrderBook?

I use 1inch API to get a list of order limits by the specific token. https://portal.1inch.dev/documentation/orderbook/introduction pair AXL/axlUSDC and I get a response something like that: [ { ...
red_space's user avatar
0 votes
0 answers
37 views

Coinbase API/SDK for converting USD to USDC without fees

I want to use some API/SDK of Coinbase in my dapp for converting USD to USDC (buying USDC) without fees in Polygon network, like on Coinbase web-site. But that should be handled without creating a ...
Anastasia Martyniuk's user avatar
1 vote
0 answers
28 views

Represent UUIDv4 string as bytes16 in event topic

I am trying to emit an Event with UUIDv4 indexed string. Example contract: contract EventEmitter { event ExampleEvent(string indexed id); function dispatchEvent(string memory _uuid) public { ...
Marcin's user avatar
  • 111
0 votes
0 answers
31 views

Safely converting 1 WEI to the current ETH/USD Chainlink price

Let c be the current floating point price of ETH/USD precise to 8 decimal places. Since Solidity cannot store floating points, getting the current price of ETH/USD from Chainlink's data feed returns c ...
nostonksafrica's user avatar
0 votes
0 answers
12 views

UNKNWON TRANSACTION TO MY WALLET

I received that amount from an unknown source. what also troubles me is that my wallet displaces a much larger amount than i received which i cant explain.my gool is to convert that amount to EUR but ...
niko's user avatar
  • 1
3 votes
1 answer
184 views

How to convert a uint256 array to a bytes32 array in Solidity?

Suppose I have a uint256[] array in Solidity. What's the easiest way to convert it to a bytes32 array?
Paul Razvan Berg's user avatar
0 votes
2 answers
342 views

How do i convert Boolean to String in Solidity?

The problem is pretty simple: I want to concatenate boolean values to string values. I order to do this, i assume they have to first be converted into strings and then concatenated. Could someone ...
PupSt4r's user avatar
  • 65
1 vote
0 answers
79 views

Convert this connection code from Loom testnet to Goerli Testnet

This is a utils/common file for connecting to Loom testnet. const fs = require('fs') const Web3 = require('web3') const { Client, NonceTxMiddleware, SignedTxMiddleware, LocalAddress, CryptoUtils, ...
Vidhan Mangla's user avatar
0 votes
2 answers
438 views

Convert bytes20 to address in assembly

Can you convert a bytes20 to address in assembly (not solidity-typecasting)? If so, how?
dNyrM's user avatar
  • 938
0 votes
1 answer
126 views

Convert from Bytes[32] to bytes32 or bytes8 vyper

In vyper, how can I convert: response: Bytes[32] = raw_call(your_contract_address, call_data, max_outsize=32) to a bytes32 or even just take the first 8 bytes? response: bytes8 = ?
Patrick Collins's user avatar
2 votes
1 answer
137 views

convert bytes array to string array vyper

Let's say I have a bytes array as such: Bytes[4] = b"\x00" How would I convert this to a string?
Patrick Collins's user avatar