#NEWLINE# @ Board . method ( path = 'board' , http_method = 'POST' , name = 'board.getmove' ) #NEWLINE# def BoardGetMove( self , board ) : #NEWLINE# #INDENT# if ( not ( ( len ( board . state ) == 9 ) and ( set ( board . state ) <= set ( 'OX-' ) ) ) ) : #NEWLINE# #INDENT# raise endpoints . BadRequestException ( 'Invalid board.' ) #NEWLINE# #UNINDENT# board . MoveOpponent ( ) #NEWLINE# return board