@Override
        public ClientEndpointDiscoveryTrait createTrait(ShapeId target, Node value) {
            ObjectNode objectNode = value.expectObjectNode();
            Builder builder = builder()
                    .sourceLocation(value)
                    .operation(objectNode.expectStringMember(OPERATION).expectShapeId());
            objectNode.getStringMember(ERROR).ifPresent(error -> builder.error(error.expectShapeId()));
            ClientEndpointDiscoveryTrait result = builder.build();
            result.setNodeCache(objectNode);
            return result;
        }
Set the error shape which indicates to a client that an endpoint
they are using is no longer valid.

<p>This error MUST be bound to every operation bound to the service
which is marked with an {@link ClientDiscoveredEndpointTrait}.</p>

@param error The ShapeId of the invalid endpoint error.
@return Returns the builder.
smithy-aws-traits/src/main/java/software/amazon/smithy/aws/traits/clientendpointdiscovery/ClientEndpointDiscoveryTrait.java