strconv.Itoa() expects a value of type int, so you have to give it that:

log.Println("The amount is: " + strconv.Itoa(int(charge.Amount)))

But know that this may lose precision if int is 32-bit (while uint64 is 64), also sign-ness is different. strconv.FormatUint() would be better as that expects a value of type uint64:

log.Println("The amount is: " + strconv.FormatUint(charge.Amount, 10))

For more options, see this answer: Golang: format a string without printing?

If your purpose is to just print the value, you don't need to convert it, neither to int nor to string, use one of these:

log.Println("The amount is:", charge.Amount)
log.Printf("The amount is: %d\n", charge.Amount)
Answer from icza on Stack Overflow
๐ŸŒ
YourBasic
yourbasic.org โ€บ golang โ€บ convert-int-to-string
Convert between int, int64 and string ยท YourBasic Go
Warning: In a plain conversion the value is interpreted as a Unicode code point, and the resulting string will contain the character represented by that code point, encoded in UTF-8. ... Use strconv.FormatInt to format an int64 in a given base.
Discussions

c++ - converting _int64 to a string - Stack Overflow
I had a question when providing an API if I ask for them to give me a _int64 10 digit hexadecimal number but my function internally takes strings how do I effectively convert that... as of right... More on stackoverflow.com
๐ŸŒ stackoverflow.com
c - How to convert string to int64_t? - Stack Overflow
Slightly pedantic point: what you're asking is not how to convert char * to int64_t (if you wanted that, a simple cast would be the answer) but instead how to convert a string pointed to by the char *, which represents a number in some human-oriented textual convention like a decimal string, ... More on stackoverflow.com
๐ŸŒ stackoverflow.com
The risks of converting int64 to string using a combination of "int()" and "strconv.Itoa"
int is just 32 bits wide on 32 bit systems. So int(amt) on those systems discards the upper 32 bits of the int64. Effectively int(amt) is int(amt % 1<<32) on 32 bit systems. package main import ( "fmt" "strconv" ) func main() { var i int64 = 1 << 32 fmt.Println(strconv.Itoa(int(i))) } Running with GOARCH=amd64 go run main.go outputs 4294967296 Whereas running with GOARCH=386 go run main.go outputs 0 More on reddit.com
๐ŸŒ r/golang
9
2
January 27, 2023
Convert Int64 to string
Hi I would like my c# Int64 values to be converted to string types. How do I do that ? More on github.com
๐ŸŒ github.com
2
February 15, 2018
๐ŸŒ
Google Groups
groups.google.com โ€บ g โ€บ borland.public.cppbuilder.language โ€บ c โ€บ AQc2Bt3pbfs
Converting __int64 to String?
Stringstreams are in the <sstream> header. ... Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message ... I think there's a problem in the conversion from 'unsigned __int64' and 'char' types.
๐ŸŒ
Microsoft Learn
learn.microsoft.com โ€บ en-us โ€บ dotnet โ€บ api โ€บ system.int64.tostring
Int64.ToString Method (System) | Microsoft Learn
The string representation of the ... no leading zeroes. The following example displays an Int64 value using the default ToString() method....
๐ŸŒ
Golang Docs
golangdocs.com โ€บ home โ€บ golang int64 to string conversion
Golang int64 to string conversion - Golang Docs
August 19, 2022 - We can use strconv package to convert golang int64 to string format. There are two functions - Itoa() and FormatInt() for int to string conversion.
Find elsewhere
๐ŸŒ
Reddit
reddit.com โ€บ r/golang โ€บ the risks of converting int64 to string using a combination of "int()" and "strconv.itoa"
r/golang on Reddit: The risks of converting int64 to string using a combination of "int()" and "strconv.Itoa"
January 27, 2023 -

I've been reading some articles online why converting an int64 value to string using a combination of int() and strconv.Itoa isn't really a good idea but I am having issues trying to really grasp what it's all about. I understand there could be some inconsistencies during the conversion process but I am unable to grasp why such inconsistency could happen. I'll really appreciate it if some can explain to me like I am 5. A sample of what I am referring to can be seen below. Thanks

var amt int64 = 90 
strconv.Itoa(int(amt))
๐ŸŒ
Convert String
convertstring.com
Convert String - Online String Conversion tools
Convert String offers free and secure online tools for converting strings between formats. UrlEncode, UrlDecode, Base64 encode, Base64 decode and MD5 hashing algorithms are among the many free tools available.
๐ŸŒ
Go Packages
pkg.go.dev โ€บ strconv
strconv package - strconv - Go Packages
Package strconv implements conversions to and from string representations of basic data types.
๐ŸŒ
Go language Tutorial
golangtutorial.dev โ€บ home โ€บ tips โ€บ how to convert an int32 & int64 to string in go
How to Convert an int32 & int64 to string in Go - Go language Tutorial
November 5, 2020 - To Convert an int to string in Go, use strconv.Itoa()(int32 to string) and strconv.FormatInt()(int64 to string) functions which are part of Goโ€™s strconv package.
๐ŸŒ
Base64Encode.org
base64encode.org โ€บ enc โ€บ integer
Base64 Encoding of "integer" - Online
Meet Base64 Decode and Encode, a simple online tool that does exactly what it says: decodes from Base64 encoding as well as encodes into it quickly and easily.
๐ŸŒ
GeeksforGeeks
geeksforgeeks.org โ€บ c# โ€บ int64-parsestring-method-in-c-sharp-with-examples
Int64.Parse(String) Method in C# with Examples - GeeksforGeeks
July 12, 2025 - // C# program to demonstrate // Int64.Parse(String) Method using System; class GFG { // Main Method public static void Main() { // passing different values // to the method to check checkParse("9223372036854775807"); checkParse("29,22337,20368547"); checkParse("-922337203685477"); checkParse(" 9223372075807"); } // Defining checkParse method public static void checkParse(string input) { try { // declaring Int64 variable long val; // getting parsed value val = Int64.Parse(input); Console.WriteLine("'{0}' parsed as {1}", input, val); } catch (FormatException) { Console.WriteLine("Can't Parsed '{0}'", input); } } }
๐ŸŒ
GitHub
github.com โ€บ frhagn โ€บ Typewriter โ€บ issues โ€บ 254
Convert Int64 to string ยท Issue #254 ยท frhagn/Typewriter
February 15, 2018 - That call the following method(How do I return a string type ?): Typewriter.CodeModel.Type GetType(Property c) { var type = c.Type; var fr = c.Type.Attributes.FirstOrDefault(a => String.Equals(a.Name, "Description", StringComparison.OrdinalIgnoreCase)); if(c.Type == "Int64") { //TODO: return type of string Typewriter.CodeModel.Type ??????
Author ย  bandersen22000
๐ŸŒ
Browserling
browserling.com โ€บ tools โ€บ decimal-to-text
Decimal to Text Converter - Convert Decimal to String - Online - Browserling Web Developer Tools
Useful, free online tool that converts decimal integer values to plain text. No ads, nonsense, or garbage, just a dec to text converter. Press a button โ€“ get the result.
๐ŸŒ
TutorialsPoint
tutorialspoint.com โ€บ article โ€บ int64-tostring-method-in-chash
Int64.ToString() Method in C#
March 17, 2026 - The method in C# is used to convert a 64-bit integer (long) value to its equivalent string representation. This method provides multiple overloads for different formatting options, allowing you to control how the numeric value appears as text.