public async Task <IActionResult> PutTripRecords(Guid id, TripRecords tripRecords)
        {
            if (id != tripRecords.Id)
            {
                return(BadRequest());
            }

            _context.Entry(tripRecords).State = EntityState.Modified;

            try
            {
                await _context.SaveChangesAsync();
            }
            catch (DbUpdateConcurrencyException)
            {
                if (!TripRecordsExists(id))
                {
                    return(NotFound());
                }
                else
                {
                    throw;
                }
            }

            return(NoContent());
        }
        public async Task <ActionResult <TripRecords> > PostTripRecords(TripRecords tripRecords)
        {
            _context.TripRecords.Add(tripRecords);
            await _context.SaveChangesAsync();

            // Begin coin transaction
            var blockChain = new BlockChain(proofOfWorkDifficulty: 2, miningReward: tripRecords.CoinsEarned);

            Console.WriteLine("BALANCE of the miner: {0}", blockChain.GetBalance(Recipient));
            PrintChain(blockChain);

            return(CreatedAtAction("GetTripRecords", new { id = tripRecords.Id }, tripRecords));
        }