I’m looking for a way to clean up the following json string in C# to be more usable.
“?{\”token\”:\”I3dt-MIByyWD5-XqF6VT3hQSk8qvy9r6\”}”
basically just for a way to strip it down to
“token:I3dt-MIByyWD5-XqF6VT3hQSk8qvy9r6” or just “I3dt-MIByyWD5-XqF6VT3hQSk8qvy9r6”
I assume that a would be good for accomplishing this but unfortunately i’ve never written one before and a bit lost on how to get what im looking for using one. The parsing is happening in C# BTW.
EDIT: Correction a regular expression probably wont do what i want… i want to format the string.. not just validate it.
It is better to parse it into a
JSONobject, then using theJSONAPI, to get the value of thetokenkey from there.